The Queen visited Prince Philip in a hospital in London on Monday, three days after an operation on his abdomen.
Buckingham Palace said the prince will cease public engagements for two months as a result of the operation.
The palace said he was "comfortable and in good spirits". He will remain in hospital for up to two weeks.
Prince Philip, who marked his 92nd birthday in hospital, also received a visit from his youngest son, Prince Edward.
The Queen was shown on BBC television entering the London Clinic, where Prince Philip was admitted on Friday for an "exploratory operation following abdominal investigations".
The palace has not given further details of his condition.