Egyptian President Hosni Mubarak has stepped down and named a military council to run the country's affairs, state television said on Friday after 18 days of mass protests against his rule.
Egypt's higher military council said it would announce measures for a transitional phase after Mubarak stepped down.
In a statement, titled "Communique No. 3", it praised Mubarak for stepping down "in the interests of the nation" and said it "salutes the martyrs" who lost their lives in the unrest.
"We know the extent of the gravity and seriousness of this issue and the demands of the people to initiate radical changes," the statement said. "The higher military council is studying this issue to achieve the hopes of our great people."
"The council will issue a statement outlining the steps and procedures and directives that will be taken, confirming at the same time that there is no alternative to the legitimacy acceptable to the people," it added.
A source had earlier released the statement to Al Arabiya before it was read out on television.
Hundreds of thousands of Egyptian protesters waved flags, cried, cheered and embraced in Cairo's Tahrir Square on Friday, shouting "God is Great" when the resignation of President Hosni Mubarak was announced.
Former U.N. nuclear chief Mohamed ElBaradei s aid, "This is the greatest day of my life. The country has been liberated."
A grim-faced and ashen Vice President Omar Suleiman announced the handover on state television after an extraordinary national outpouring of rage brought more than a million furious demonstrators onto the streets.
"Taking into consideration the difficult circumstances the country is going through, President Mohammed Hosni Mubarak has decided to leave the post of president of the republic and has tasked the Supreme Council of the Armed Forces to manage the state's affairs," Suleiman said.
Earlier, the 82-year-old strongman had flown out of Cairo to his holiday retreat at Sharm el-Sheikh on the Red Sea, his ruling party said.
As news spread cries of "Allahu Akbar" -- God is greatest! -- and howls of victory rang out in the streets of the capital and firecrackers exploded.
In Tahrir Square several protesters fainted with the emotion of the moment following two weeks of protest.
The plaza has become a focal point of the revolt since it was occupied by protesters in late January, and earlier in the day had been thronged by hundreds of thousands of Egyptians, who prayed and chanted abuse at Mubarak.
"People here don't care if he's in the palace or not. We want him to quit the presidency," said 40-year-old Mohammed Hamdan, who works for an oil firm, as he joined the protest outside Mubarak's palace in the Cairo suburbs.
"He has to leave the country, our demands are clear, we want the entire NDP to be dissolved and to get out because they have destroyed the country," said Magdi Sabri, a smartly dressed middle-aged man outside state television.
President Mohammed Hosni Mubarak has decided to leave the post of president of the republic
Vice President Omar Suleiman
In a show of solidarity in at least lower levels of the army, three Egyptian officers shed their weapons and uniforms and joined the protesters.
An impassioned preacher addressed the military in his sermon, exhorting them to "act in a way that will be acceptable to God on judgement day," shortly before fainting and being carried away through the crowd.
On Thursday night, hundreds of thousands had crowded into Tahrir Square to hear a speech that was widely expected to be Mubarak's last as president.
Instead, he delegated some of his powers to his ally and Egypt's former intelligence supremo, Omar Suleiman, while vowing he would stay in office until September and one day die in Egypt, ruling out a flight into exile.
Mubarak had also been on a collision course with the international community, and in particular Egypt's key ally and donor, Washington.
In his speech on Thursday, he took a swipe at the United States and other countries that want a faster transition to democracy in the Arab world's most populous nation, vowing: "I have never bent to foreign diktats."
American President Barack Obama reacted with a flash of anger of his own, saying Mubarak had failed to map out "meaningful or sufficient" change, or to speak clearly enough to Egypt and the world.