The 88-year-old pope gave a thumbs up and acknowledged the crowd after he was wheeled out onto the balcony overlooking the main entry of Rome’s Gemelli hospital, where hundreds of people had gathered on a brilliant Sunday morning.
Chants of “Viva il papa!” and “Papa Francesco” erupted from the crowd.
His appearance came before he was due to be released and return home to the Vatican for a two-month period of rest and convalescence.
The Argentine pope, who has chronic lung disease and had part of one lung removed as a young man, was admitted to Gemelli on February 14 after a bout of bronchitis worsened.
Doctors later diagnosed a complex bacterial, viral and fungal respiratory tract infection and soon thereafter, pneumonia in both lungs.
His 38-day stay was the longest of his 12-year papacy and the second longest in recent papal history, and had raised the prospect of a papal resignation or funeral.