The National Transitional Council (NTC) has declared the liberation of Libya, eight-months after the uprising against Muammar Gaddafi's 42-year rule began.
Thousands of people in Kish Square in Benghazi, Libya's second city, sang the national anthem and waved flags, both of which date back to the monarchy which Gaddafi overthrew in a 1969 coup.
Mustafa Abdel Jalil, the leader of the NTC, kneeled in prayer after taking the stand in the celebration on Sunday and promised to uphold Islamic law.
"We as a Muslim nation have taken Islamic sharia as the source of legislation, therefore any law that contradicts the principles of Islam is legally nullified," Jalil told the crowd.
The NTC leader thanked the Arab League, the United Nations, and the European Union for supporting the uprising which ended with Gaddafi's death on Thursday.
Live Box 20115613924415945
"All the martyrs, the civilians and the army had waited for this moment. But now they are in the best of places ... eternal heaven," he said, shaking hands with supporters.
"The revolution began as a peaceful one. But it was faced with violence," he told the tens of thousands of Libyans gathered in the city, where fighting against Gaddafi erupted in February.
An NTC official who opened the ceremony, said: "We declare to the whole world that we have liberated our beloved country, with its cities, villages, hill-tops, mountains, deserts and skies."
Abdul Hafiz Ghoga, the council's vice-chairman, said at the ceremony that Libya would uphold all international agreements and treaties.
"The Libyan people, as they establish a state of law, firstly, assure the world of their respect for all Libya's signed agreements according to international standards," Ghoga said.
US President Barack Obama congratulated the people of Libya with what he called a "historic declaration of liberation".
"After four decades of brutal dictatorship and eight months of deadly conflict, the Libyan people can now celebrate their freedom and the beginning of a new era of promise," a statement from Obama said.
The NTC has said it will now embark on the process of building a democracy and hold the country's first free elections next year.
Libya's new leaders have a "very limited opportunity" to put aside their differences, said Mahmoud Jibril, the country's interim prime minister, as he announced he was stepping down on Saturday.
Jibril said that progress in Libya would require stronger resolution from the NTC's leaders as well as from the six million citizens of the country.
Jibril said that the first elections for a national constituent assembly would take place "within a period of eight months".
Regional armed groups
The NTC's forces were largely comprised of loosely organised local armed groups that sprang up in towns where citizens wished to see Gaddafi's rule ended. These groups remain armed, and it is unclear what role they expect to play going forward following Abdel Jalil's announcement.
The armed groups in Benghazi and Misrata were particularly influential, with the latter playing a key role in taking Tripoli, the capital, and in capturing Gaddafi from a drainage pipe outside Sirte, his last stronghold. He was later killed before he could be transferred into NTC custody.
The fighters brought Gaddafi's body back to Misrata, where it has been on display for two days in a cold storage container for Libyans to see.
Concerns regarding the manner of Gaddafi's death remain unaddressed, meanwhile, Navi Pillay, the United Nations Human Rights Commissioner, has called for an investigation into the killing, which appeared to be a summary execution.
The questions are not limited to international observers. On Saturday, Waheed Burshan, a member of the NTC, told Al Jazeera that Gaddafi had clearly been captured alive and that there should be an investigation into how he was killed.
"We found that he was alive and then he was dead. And as far as we can tell there was no fight," he said.
"Was there a fight when transporting him to Misrata? We don’t know. But there was definitely a time gap and I am sure an investigation will happen."
'Killed in crossfire'
Burshan’s comments contradicted Jibril's account that Gaddafi died in a crossfire.
Jibril said on Sunday that a bullet that hit Gaddafi's head may have been fired by one of his own guards during the shootout with government forces.
"He was taken out, put in that truck and on their way to the field hospital they got crossfire on both sides and they didn't know if the bullet in the head was coming from his own security brigades or from the revolutionary people," Jibril told reporters at a business forum in Jordan.
Live Box 201142012730683527
I have no reason ... to doubt the credibility of that report," he said.
But Othman el-Zentani, a doctor who examined Gaddafi's body, said later only that the dictator had been "killed by bullets" adding: "My autopsy report is not finished."
Zentani said he could not give more details as he had to "wait for the green light from my superior," prosecutor-general Abdelaziz al-Ahsadi.
Arguments have also arisen over what to do with Gaddafi's body, as it has not been accorded a swift burial as is required under Islamic law and local tradition. Until now, his body has been stored in a vegetable market freezer in Misrata, drawing large crowds wanting to view and take pictures of the remains.
The body is already beginning to decompose, and those viewing it on Saturday were obliged to cover their faces with surgical masks.
Gaddafi's family, currently in exile in Algeria, want his body and that of his son, Mutassim, handed over to members of his tribe.
One of the people waiting to see the former Libyan leader's body in Misrata told Al Jazeera: "He [Gaddafi] ruled us for 42 years. In his life, it was impossible to see him, so we are here to take a look."
Source: Al Jazeera and agencies