Gambia's former leader Yahya Jammeh has sought exile in Equatorial Guinea after stepping down under pressure from West African nations to accept that he lost a December election to President Adama Barrow.
His exit ends rising tension as thousands of troops from Senegal and Nigeria who entered the tiny country on Thursday were poised to swoop on the capital Banjul. It also paves the way for the return home of Barrow, who was sworn in as leader at the Gambian embassy in Senegal on Thursday.
Mr Jammeh took power in a coup in 1994, and his government is accused of torturing and killing perceived opponents. There were few celebrations in Banjul as news of his departure spread, but some people said they felt relief after years of fear.
"The rule of fear has been banished from Gambia for good," Barrow told a crowd at a Dakar hotel on Friday, once it became clear a deal had been struck for Jammeh to relinquish power.
"To all of you forced by political circumstances to flee our country, you now have the liberty to return home," said Barrow, 51, who worked as a property developer and led an opposition coalition few thought would win the December 1 vote.
Mr Jammeh's security forces offered no resistance to soldiers from West African bloc ECOWAS. Around 4,000 troops are still there and some will remain to ensure security, said Marcel de Souza, head of the ECOWAS commission.
Mr Jammeh was accompanied onto the plane by Guinean President Alpha Conde, who mediated the terms of his exit with Mauritanian President Mohamed Ould Abdel Aziz and others.
He is the first president to peacefully hand over power in Gambia since independence from Britain in 1965.