HARARE - Robert Mugabe resigned as Zimbabwe's president on Tuesday, swept from power as his 37-year reign crumbled within days of a military takeover.
The move looks set to bring an end to Zimbabwe's worst political crisis since the country won independence from Britain in 1980.
The bombshell announcement was made by the Speaker at a special joint session of parliament which had convened to impeach the 93-year-old who has dominated every aspect of Zimbabwean public life for decades.
On the streets, the news sparked an explosion of wild celebration.
Car horns honked and people erupted into ecstatic cheers and frenzied dancing.
"I Robert Gabriel Mugabe in terms of section 96 of the constitution of Zimbabwe hereby formally tender my resignation... with immediate effect," said the letter which was read out by parliamentary speaker Jacob Mudenda.
"My decision to resign is voluntary on my part. It arises from my concern for the welfare of the people of Zimbabwe and my desire to ensure a smooth, peaceful and non-violent transfer of power that underpins national security, peace and stability."
In a highly symbolic scene, a man in a white shirt took down a portrait of Mugabe from the wall of a room inside the building where parliament sat for its extraordinary session. Another bystander replaced it with an image of Mnangagwa.
Outside, a man held up a smiling new-born wearing white pyjamas, prompting rapturous cheering from the crowd.
It capped an unprecedented week in which the military seized control and tens of thousands of ordinary Zimbabweans took to the streets in an extraordinary show of defiance to demand that Mugabe leave.
'37 years under dictatorship'
"I am so happy that Mugabe is gone, 37 years under dictatorship is not a joke. I am hoping for a new Zimbabwe ruled by the people," Tinashe Chakanetsa, 18, told AFP.
Men were breakdancing, women were singing and children were in tears as the news began to sink in, all brandishing national flags and praising General Constantino Chiwenga who led the army takeover.
"It's shocking, that guy is powerful, very powerful," said Barber Wright Chirombe who was also taking part in the euphoric celebrations.
Mugabe had ruled Zimbabwe almost unopposed since independence -- but efforts to position his wife Grace as his successor triggered fury in the military that had underpinned his regime.
His grip on power was shattered last week when armoured military vehicles took to the streets, blockaded parliament and soldiers placed the president under house arrest in an operation that had all the hallmarks of a coup.
But the generals stressed they were simply "arresting" criminals around Mugabe -- a reference to Grace's supporters -- and they even allowed the one-time liberation hero to deliver a televised speech and appear at a public function.
As the crisis grew, the ruling ZANU-PF party, an instrument of Mugabe's ruthless decades-long rule, removed him as party leader and began parliamentary proceedings to have him impeached.
"The man had run out of options. The writing was on the wall... He was in a state of denial," said Innocent Gonese, chief whip of the main opposition Movement for Democratic Change party.
"Mugabe might have been hoping that the impeachment process would not succeed, that it might stumble in getting the numbers together. But I think when he saw the turnout (of lawmakers) he probably realised he'd better jump before he was pushed," said Derek Matyszak, an analyst at the Pretoria-based Institute for Security Studies.
Mnangagwa in the wings
His likely successor is former vice president Emmerson Mnangagwa, whose dismissal on November 6 triggered the crisis.
A former close ally of Mugabe, Mnangagwa had been Grace Mugabe's chief rival to succeed him. Grace has not been seen since the start of the crisis.
However, under Zimbabwe's constitution, it is second Vice President Phelekezela Mphoko who would ordinarily take over as head of state.
"I think we're going to see Emmerson Mnangagwa sworn in very quickly... As far as I understand Mphoko is not in the country. Then the cabinet should meet if there's no president or vice president and appoint one," said Matyszak, the analyst.
Gonese, the opposition politician, agreed suggesting that the ruling party could appoint a successor in "less than two hours".
British Prime Minister Theresa May said the resignation gave Zimbabwe "an opportunity to forge a new path free of the oppression that characterised his rule".
The United States embassy in Harare described it as an historic moment for Zimbabwe.
On Saturday, in scenes of public euphoria not seen since independence, huge crowds marched and sang their way through Harare and other cities in peaceful celebrations to mark his fading power.
Such open dissent would have been routinely crushed by security forces before the past week's shock events.
Most Zimbabweans have only known life under Mugabe's rule, which was defined by violent suppression, economic collapse and international isolation.