Zimbabwe’s President Robert Mugabe has resigned, parliament speaker Jacob Mudenda has said.
A letter from Mr Mugabe said the decision was voluntary and he had made it to allow a smooth transfer of power.
The announcement halted an impeachment hearing that had begun against him.
The ruling Zanu-PF party says former vice-president Emmerson Mnangagwa will succeed Mr Mugabe, in power since 1980.
Mr Mnangagwa’s sacking earlier this month triggered a political crisis.
It had been seen by many as an attempt to clear the way for Grace Mugabe to succeed her husband as leader and riled the military leadership, who stepped in and put Mr Mugabe under house arrest.
After the resignation report, lawmakers roared in jubilation.
Mr Mugabe, 93, was until his resignation the world’s oldest leader. He had previously refused to quit despite last week’s military takeover.
According to the constitution his successor should be the current vice-president, Phelekezela Mphoko, a supporter of Grace Mugabe.
But Zanu-PF chief whip Lovemore Matuke told Reuters news agency that Mr Mnangagwa would be in office “within 48 hours”.
1924: Born
1964: Imprisoned by Rhodesian government
1980: Wins post-independence elections
1996: Marries Grace Marufu
2000: Loses referendum, pro-Mugabe militias invade white-owned farms and attack opposition supporters
2008: Comes second in first round of elections to Morgan Tsvangirai who pulls out of run-off amid nationwide attacks on his supporters
2009: Amid economic collapse, swears in Mr Tsvangirai as prime minister, who serves in uneasy government of national unity for four years
2017: Sacks long-time ally Vice-President Emmerson Mnangagwa, paving the way for his wife Grace to succeed him. Army intervenes and forces him to step down.
Source: BBC