Jubilant Libyans have voted for a new parliament in their first free election in decades, but violence and protests in the restive east underscored the challenges ahead as the oil-rich nation struggles to restore stability.
Women ululated while men distributed sweets and the elderly struggled to get to polling centres in a show of joy over the most visible step towards democracy since dictator Muammar Gaddafi was killed by rebel forces last October after months of bitter civil war.
"Look at the lines. Everyone came of his and her own free will. I knew this day would come and Gaddafi would not be there forever," said Riyadh al-Alagy, a 50-year-old civil servant in Tripoli. "He left us a nation with a distorted mind, a police state with no institutions. We want to start from zero."
But attacks on polling centres in the east - where anger over perceived domination by rivals in the west is fuelling a drive for autonomy - laid bare the rifts threatening to tear the nation apart. One person was killed and two wounded in the country's east.
Still, the election for a 200-seat parliament, which will be tasked with forming a new government, was the latest milestone in a revolution stemming from the Arab Spring revolts that led to the successful ousting of authoritarian leaders in Tunisia, Egypt and later Yemen.
Nearly 2.9 million Libyans, or 80% of those eligible to vote, have registered for the election and more than 3,000 candidates have plastered the country with posters and billboards. Electoral officials said turnout was 60% and counting of the ballots had begun.
Islamists hope to rise to power in Libya where they were long repressed under Gaddafi's secular rule. One of the main contenders in the race was the Muslim Brotherhood's Justice and Construction party, which has led one of the best organised and most visible campaigns.
Three other parties also expected to perform well were former prime minister Mahmoud Jibril's secular Alliance of National Forces; former jihadist and rebel commander Abdel-Hakim Belhaj's Al-Watan; and the National Front, one of Libya's oldest political groups.
US senator John McCain, an Arizona Republican, gave the election a clean bill of health during a visit to Tripoli. "Turnout is very high, polls crowded and people are obviously enthusiastic. Overall it is a successful operation," he said.
The new parliament is temporary and must form a new government that will take over until a constitution is drafted so fresh elections can be held next year.