According to the Buckingham Palace, Prince Philip has had a successful heart operation.
The intervention on Wednesday because of a long-standing heart condition in the 99-year-old went well, the palace said on Thursday.
Queen Elizabeth II's husband will remain in the hospital for a few more days for treatment and recovery.
"At least until the end of the week" in the hospital
Prince Philip has been hospitalized since February 16.
At first it was said from Buckingham Palace that it was a "precautionary measure" because he had felt uncomfortable.
A few days later there was talk of an infection.
On Monday, the 99-year-old was transferred to the state St. Bartholomew's Clinic in London, which also enjoys a high international reputation as a heart center.
The news heightened general concern about the health of the prince, who will celebrate his 100th birthday on June 10.
The palace said on Monday that the doctors would “continue to treat an infection and also carry out tests and observations for pre-existing heart problems”.
Prince Philip responded to the treatment, but had to stay "at least until the end of the week" in the hospital.
Philip and Elizabeth have been married since 1947.
In 2017, Prince Philip largely withdrew from public life.
He had repeatedly struggled with health problems in recent years.
In April 2018, he was given an artificial hip joint in a clinic.
In the past few years, Philip had to go to hospital from time to time because of various infections.
In 2011 a stent was placed on his heart.
The 94-year-old queen and her husband were first vaccinated against the coronavirus in January.
At the beginning of the pandemic, both of them had withdrawn to Windsor Castle because of their old age in order to keep the risk of infection as low as possible.
Despite her husband's illness, the Queen stuck to her duties.
On Tuesday evening, as is traditional, she spoke to Finance Minister Rishi Sunak before he gave his budget speech in parliament on Wednesday.
Prince Charles visited his father in the hospital in between.