JOHANNESBURG – Nelson Mandela went home in an ambulance on Sunday after nearly three months in a hospital that became the focus of a global outpouring of concern, but authorities said the health of the former South African president remained critical and sometimes unstable.

The return of the 95-year-old leader of the anti-apartheid movement to his home in an affluent neighborhood of Johannesburg allows his family to share time with him in a more intimate setting.

The office of South African President Jacob Zuma said Mandela will receive the same level of intensive care that he did in the hospital, administered by the same doctors.

Zuma’s office said the team of doctors treating Mandela, also known by his clan name Madiba, is “convinced that he will receive the same level of intensive care at his Houghton home that he received in Pretoria. His home has been reconfigured to allow him to receive intensive care there.”

The statement also said: “If there are health conditions that warrant another admission to hospital in future, this will be done.”

Mandela had been treated in a hospital in Pretoria, about 31 miles from Johannesburg, and the areas near the entrances to both the hospital and his home became makeshift shrines where people sang, prayed and left messages of support for a man who steered South Africa from white minority rule to democratic rule in a spirit of reconciliation that inspired the world.

Mandela was admitted to the hospital on June 8 for what the government described as a recurring lung infection.

One of Mandela’s daughters, Makaziwe Mandela, told The Associated Press as she left her father’s home that the family was “happy that he is home.”

Zuma’s office said Mandela “vacillated between serious to critical and at times unstable” during his stay in hospital and that “despite the difficulties imposed by his various illnesses, he, as always, displays immense grace and fortitude.”

Mandela has been particularly vulnerable to respiratory problems since contracting tuberculosis during his 27-year imprisonment. The bulk of that period was spent on Robben Island, a prison off the coast of Cape Town where Mandela and other apartheid-era prisoners spent part of the time toiling in a limestone quarry.

There has been an outpouring of concern in South Africa and around the world for the transformative figure who led the tense shift from apartheid’s white minority rule to democracy two decades ago. Zuma urged South Africans to accept that Mandela had grown old and frail, saying all they could do was pray for him.