President Thabo Mbeki has been sworn in for a second term in office on a day of celebration in South Africa - marking 10 years of multi-racial democracy.
Large crowds have gathered in Pretoria for the event
Guests at the ceremony in Pretoria included key figures in the transition from apartheid, ex-presidents Nelson Mandela and FW de Klerk.
Wild cheers and singing broke out as Mr Mandela arrived with his wife, Graca Machel, and made his way to his seat.
Choirs greeted some 40, mainly African, leaders and other dignitaries.
The inauguration coincided with celebrations for 27 April known as "Freedom Day", symbolising the end of white minority rule and the start of multi-racial democracy.
In a measured speech at the Union Buildings in the capital, President Mbeki spoke of the progress and difficulties faced in the past 10 years as well as the challenges that lie ahead.
"Endemic and widespread poverty continues to disfigure the face of our country. It will always be impossible for us to say that we have fully restored the dignity of all our people as long as this situation persists," he told the guests.
Tens of thousands of South Africans attended a spectacular show following the inauguration, next to where the ceremony was held.
Some of the country's best known musicians appeared and there was an hour-long play depicting South Africa's successes since the end of apartheid.
Among the achievements hailed were sporting successes at the African Cup of Nations and the Rugby World Cup.
Among the guests welcomed with huge cheers was Zimbabwe's President Robert Mugabe, a close regional ally of President Mbeki.
Local media reported that two five-star hotels in Pretoria refused to allow him to stay and he was instead using a guest house.
But Zimbabwe Ambassador Simon Moyo said Mr Mugabe was staying at a guest house out of choice.
Other guests at the high-security events included senior officials from football's world governing body, Fifa, who are due to decide shortly on South Africa's bid to host the World Cup in 2010.
Legal challenge dropped
South African opposition politician Patricia de Lille told Reuters news agency: "Coming back here reminds me of that exciting day when President Mandela was inaugurated. When I went out to vote it still gave me the same butterflies in the stomach."
The ruling African National congress (ANC) won a landslide victory in the 14 April elections.
DECADE OF DEMOCRACY
1.6m new houses built for poor
Stable economy, low inflation
70% households electrified
9m access to water
5.3m with HIV/Aids
Massive wealth inequality
The Inkatha Freedom Party announced it would drop its protests over election irregularities in KwaZulu-Natal province.
"It was never our intention to spoil the celebrations of our first decade of democracy," said IFP leader Mangosuthu Buthelezi.
The BBC's Barnaby Phillips in Pretoria says that while great achievements are being celebrated, President Mbeki still faces the challenge of enormous social problems in South Africa, as well as trying to restore stability and prosperity to Zimbabwe.