Sri Lanka President Gotabaya Rajapaksa has endured in a humiliating standoff with airport immigration staff blocking his exit to safety abroad, official sources said on Tuesday.
Mr Rajapaksa and his wife spent the night at a military base next to the main international airport, officials said.
He has promised to resign on Wednesday and clear the way for a "peaceful transition of power" — but became stuck in his own country on Tuesday after an attempt to flee.
It followed widespread protests against him over the country's unprecedented economic crisis.
The 73-year-old leader fled his official residence in Colombo just before tens of thousands of protesters overran it on Saturday, officials said.
As president, Mr Rajapaksa enjoys immunity from arrest. It is believed he wanted to go abroad before stepping down to avoid the possibility of being detained.
But immigration officers were refusing to go to the VIP suite to stamp his passport, while he insisted he would not go through the public facilities, fearing reprisals from other airport users.
Mr Rajapaksa's youngest brother, Basil — who resigned in April as finance minister — missed his flight early on Tuesday after a similar standoff with airport staff.
Basil Rajapaksa tried to use the paid concierge service for business travellers, but airport and immigration staff said they were withdrawing from the fast-track service with immediate effect.
"There were some other passengers who protested against Basil boarding their flight," an airport official told AFP. "It was a tense situation, so he hurriedly left the airport."
Basil, a US dual citizen, had to obtain a new passport after leaving his behind at the presidential palace when the Rajapaksas left to avoid mobs on Saturday, a diplomatic source said.
Official sources said a suitcase full of documents had also been left behind at the stately mansion along with 17.85 million rupees ($50,000) in cash, now in the custody of a Colombo court.
There was no official word from the president's office about his whereabouts, but he remained commander-in-chief of the armed forces with military resources at his disposal.
One option still open to him would be to take a navy vessel to either India or the Maldives, a defence source said.
If Mr Rajapaksa steps down as promised, Prime Minister Ranil Wickremesinghe will automatically become acting president until Parliament elects an MP to serve out the presidential term, which ends in November 2024.
Mr Rajapaksa is accused of mismanaging the economy to a point where the country has run out of foreign exchange to finance even the most essential imports, leading to severe hardships for its 22 million population.
Sri Lanka defaulted on its $51 billion foreign debt in April and is in talks with the IMF about a possible bailout.
The island has nearly exhausted its already scarce supplies of petrol. The government has ordered the closure of non-essential offices and schools to reduce commuting and save fuel.