The Duke of Edinburgh has been discharged from hospital following "successful" heart surgery earlier this month.
Prince Philip, 99, spent 28 nights in hospital under medical care after being admitted to King Edward VII's hospital on 16 February as a precautionary measure after feeling unwell - his longest ever stay.
Buckingham Palace said in a statement: "The Duke of Edinburgh has today been discharged from King Edward VII's Hospital and has returned to Windsor Castle, following treatment for an infection and a successful procedure for a pre-existing condition.
"His Royal Highness wishes to thank all the medical staff who looked after him at both King Edward VII's Hospital and St Bartholomew's Hospital, and everyone who has sent their good wishes."
READ: The Queen marks St Patrick's Day with special message
WATCH: Prince Philip leaves hospital after four-week stay
It is understood that the Duke is in good spirits.
Prince Philip was transferred to St Bartholomew's on 1 March, which is home to Barts Heart Centre – Europe's largest specialised cardiovascular service.
A few days after the heart procedure, he was transferred back to King Edward's to recuperate and to continue his treatment.
MORE: Prince Charles and Camilla melt fans' hearts with throwback Mother's Day photos
MORE: The sweet way Prince Edward and Sophie spent Earl's birthday
The Duke of Edinburgh left hospital on Tuesday after a month-long stay
The Prince of Wales visited his father in hospital on 20 February, making a 200-mile round-trip from his home, Highgrove, in Gloucestershire.
Prince Charles and his wife Camilla carried out a public engagement at a pop-up vaccination centre at Finsbury Park Mosque in north London on Tuesday, just hours after Prince Philip was discharged from hospital.
The Prince revealed he is "thrilled" that his 99-year-old father has returned to Windsor Castle after leaving hospital and that he had "spoken to him several times".
Prince Philip underwent successful heart surgery
The Duke, who is set to mark his 100th birthday on 10 June, has been residing at Windsor Castle with the Queen throughout the lockdowns.
The couple travelled to their Scottish estate Balmoral last August to spend time with family when restrictions were eased. They also spent time privately at Sandringham in Norfolk last September.
Prince Philip retired from public duties in August 2017, aged 96, having completed 22,219 solo engagements since 1952.
The Queen and the Duke recently welcomed their ninth great-grandchild with the birth of Princess Eugenie and Jack Brooksbank's son August Philip Hawke Brooksbank; the baby's middle name was a sweet nod to Eugenie's paternal grandfather.
Make sure you never miss a ROYAL story! Sign up to our newsletter to get all of our celebrity, royal and lifestyle news delivered directly to your inbox.