Nelson Rolihlahla Mandela, the father of the nation, died on December 5 2013 at the age of 95.
President Jacob Zuma made the announcement from the Union Buildings in Pretoria on Thursday night. He said Mandela passed away at 8.50pm at his home in Houghton, Johannesburg, surrounded by his wife, Graça Machel and members of his family.
Zuma said Mandela would have a state funeral and that flags would fly half-mast from December 6 until after the funeral.
Zuma called on South Africans to "recall the values for which Madiba fought".
Mandela was hospitalised on June 8 with a recurring lung infection. Initial reports from the Presidency suggested Mandela was stable, although his condition was serious. But on June 23, the Presidency announced that Mandela's condition had deteriorated and he was critical.
Court affidavits soon confirmed that the former statesman was on an assisted-breathing, life support machine. More reports emerged about Mandela in the days that followed — that he was in a "permanent vegetative state" — although the presidency denied these, maintaining that he was "critical yet stable".
On his 95th birthday, July 18, Zuma announced an improvement in Mandela's health. Mandela was discharged from hospital in September and transported to his home in Houghton. In November, his family said he remained "quite ill", but his pneumonia had cleared up. Zuma visited Mandela on November 18 and said he was still in a critical condition, but that he continued to respond to treatment.
On December 3, his daughter, Makaziwe Mandela, said the former president was "strong" and "courageous", although he was "on his death bed". Mandela's grandson, Ndaba Mandela, said his grandfather was "not doing well", although, "he is still with us".
His declining health has been the subject of speculation over the past few years. He was diagnosed and treated for prostate cancer in 2001 but made a full recovery. In 2011, he was admitted to hospital following a severe respiratory infection and a year later underwent a scheduled surgery for a longstanding abdominal complaint.
Mandela was plagued by recurring lung ailments in recent years. He spent 18 days in hospital at the end of 2012 and, despite receiving home-based high care thereafter, was back in hospital in March and April 2013.
There were renewed fears for his health when he returned to hospital in June. Despite assurances from the presidency that he was in a "serious but stable" condition, South Africans began preparing themselves for the worst as Mandela's family members flocked to Johannesburg, struggle stalwarts paid visits to the icon, and the world's media gathered in Qunu, Houghton and at the Pretoria hospital where he was treated.
The much-loved Mandela, known affectionately as Tata Madiba, became increasingly frail and retired from public life in 2004 at the age of 85.
Mandela's last public appearance was a brief one, at the end of the Soccer World Cup in 2010. Since then, he has split his time between his home in Houghton and his ancestral home in Qunu in the Eastern Cape.
Mandela became the symbol of the struggle against apartheid after he was convicted in the Rivonia Trial of charges of sabotage and was sentenced to life imprisonment on Robben Island.
At the end of his trial, Mandela gave a now iconic speech in which he said: "I have fought against white domination, and I have fought against black domination. I have cherished the ideal of a democratic and free society in which all persons live together in harmony and with equal opportunities. It is an ideal, which I hope to live for and to achieve. But if needs be, it is an ideal for which I am prepared to die."
Mandela, a key figure in the African National Congress, who helped found the party's youth league and armed wing, Umkhonto weSizwe, was imprisoned for 27 years before he was finally released in 1990 at the age of 71.
Mandela was awarded the Nobel Peace Prize in 1993, together with former president FW De Klerk, for the "peaceful termination of the apartheid regime and for laying the foundations for a new democratic South Africa". A year later, he was elected president in the country's first democratic election.
He stepped down from the presidency in 1999 after one term in office but continued with a busy public schedule. He brokered negotiations for peace in Rwanda, established the Mandela-Rhodes Foundation for educational scholarship, and launched the 46664 Aids fundraising foundation.