South Sudan officially became the world's newest nation at a ceremony of independence in the capital, Juba, attended by international dignitaries and tens of thousands of people.
Later in the morning, tens of thousands of South Sudanese gathered to witness the formal birth of their nation in Juba, some climbing up trees to get a good view of the events. They waited for hours in the baking heat for the ceremony to start.
Some dressed up for the celebration. This man painted the flag of the new country - the former emblem of the Sudan People's Liberation Army (SPLA) - on his head.
SPLA soldiers wounded in the civil war, in which some 1.5 million died, marched in a parade as part of the events to mark the historic day.
After the parliamentary speaker read the formal declaration of independence of South Sudan, people were emotional as they watched the new country's giant flag being raised as that of Sudan was lowered.
The crowd also sang the new national anthem, which has been blaring for weeks on South Sudanese radio for people to learn the words.
Salva Kiir (L) then signed the new constitution and took his oath of office as South Sudan's president. Next to him stood his Sudanese counterpart Omar al-Bashir (R), who later told the crowd: "The will of the people of the south has to be respected."
During the ceremony, a statue of John Garang was unveiled. Mr Garang died in a helicopter crash within months of signing the 2005 peace deal with the north and is regarded as the father of South Sudan.
"A happy day like this should not dwell on bad memories. But it is important to remember that for many generations this land has seen much suffering," Mr Kiir said in his speech.