Islamist Mohammed Morsi of the Muslim Brotherhood was elected president of Egypt with 51.7 percent of last weekend's run-off vote, defeating former general Ahmed Shafiq, the state election committee said on Sunday.
He succeeds Hosni Mubarak, who was overthrown 16 months ago after a popular uprising. The military council which has ruled the biggest Arab nation since then has this month curbed the powers of the presidency, meaning the head of state will have to work closely with the army on a planned democratic constitution.
Voter turnout at the runoff election was 51.85 percent, the chief of chief of Egypt's election commission said.
Thousands of Brotherhood supporters burst into cheers on Cairo's Tahrir Square, waving national flags and chanting "Allahu Akbar!" or God is Great, greeting a dramatic victory.
Morsi, a 60-year-old, U.S.-educated engineer who spent time in jail under Mubarak, won the first round ballot in May with a little under a quarter of the vote. He has pledged to form an inclusive government to appeal to the many Egyptians, including a large Christian minority, who are anxious over religious rule.
The military council will retain control of the biggest army in the Middle East, whose closest ally is the United States. Morsi has said he will respect international treaties, notably that signed with Israel in 1979, on which much U.S. aid depends.
"President Morsi will struggle to control the levers of state," Elijah Zarwan, senior policy fellow at the European Council on Foreign Relations, said in Cairo.
"He will likely face foot-dragging and perhaps outright attempts to undermine his initiatives from key institutions. Faced with such resistance, frustration may tempt him fall into the trap of attempting to throw his new weight around," Zarwan told Reuters. "This would be a mistake.
"His challenge is to lead a bitterly divided, fearful, and angry population toward a peaceful democratic outcome, without becoming a reviled scapegoat for continued military rule."
The announcement put an end to nerve-wracking uncertainty about who is the official winner, but promised no resolution to the power struggles between Islamists, the military and other factions.
Want to enjoy 'Zen' reading - with no ads and just the article? Subscribe todaySubscribe now