Known as "The Terminator" to family and foes alike for his ruthless crushing of Tamil rebels to end a decades-long civil war, Sri Lankan President Gotabaya Rajapaksa's rule is drawing to a close with him a fugitive and his island's economy in ruins.

Rajapaksa, one of a clan of four brothers who have dominated the country's politics in recent years, was defence secretary under his brother Mahinda's Rajapaksa's presidency from 2005-15.

He denied allegations that at least 40,000 minority Tamil civilians were killed by troops under his command during the closing months of the war, but the accusations bolstered his tough-guy image in the eyes of the majority Sinhalese.

He was also considered the architect of "white van" abductions under Mahinda, when dissidents and journalists were grabbed in unmarked vehicles and disappeared, allegedly the victims of extrajudicial killings.

He made no bones about winning the 2019 elections with the overwhelming support of his own majority Sinhala-Buddhist community.

For Sri Lanka's influential Buddhist clergy he was the reincarnation of Sinhalese warrior king Dutugemunu the Great, who is known for vanquishing a Tamil ruler.

Dutugemunu reigned for 24 years, but Rajapaksa fled less than three years into his rule -- and a resignation would make him Sri Lanka's shortest-lived directly elected president.

The 73-year-old leader flew to the neighbouring Maldives on Wednesday, four days after his presidency crumbled and tens of thousands of protesters overran his official residence.

That came after months of demonstrations demanding his resignation over an economic crisis, triggered by the coronavirus pandemic but exacerbated by mismanagement.

The former soldier marketed his lack of political expertise as a virtue but Tamil legislator Dharmalingam Sithadthan said what Rajapaksa projected as his strength was actually his weakness.

"His lack of political knowledge showed in the way he worked," Sithadthan told AFP. "He flip-flopped from one crisis to another. He thought by simply issuing orders things would materialise.

"Every time I met with him, he would say he is focused on the economy and law-and-order, but he failed in both."

Rajapaksa came to power on a manifesto promising "Vistas of Prosperity and Splendour", but according to the UN the country now desperately needs humanitarian aid.

The coronavirus pandemic hammered tourism and overseas remittances -- both mainstays of the economy -- leaving it facing a foreign exchange crisis.

Under Gotabaya Rajapaksa, Sri Lanka defaulted on its foreign debt for the first time in April and the country declared bankruptcy
Under Gotabaya Rajapaksa, Sri Lanka defaulted on its foreign debt for the first time in April and the country declared bankruptcy Sri Lankan Presidential Media Division via AFP

Lengthy power cuts are in place as the country does not have dollars to import oil for generators, the nation's 22 million people have been enduring acute shortages of food, fuel and medicines since late last year, and poverty is spreading.

When he took over in November 2019, Sri Lanka's foreign reserves were at $7.5 billion, but dropped to just "one million dollars" recently, according to prime minister Ranil Wickremesinghe.

Under Rajapaksa, Sri Lanka defaulted on its foreign debt for the first time in April. The country declared bankruptcy and inflation soared in June.

The once prosperous country recorded its worst recession in 2020 as the economy contracted 3.6 percent, and it is expected to shrink seven percent this year.

"This pariah stole our future," shouted former legislator Hirunika Premachandra leading a recent demonstration outside Rajapaksa's home. "Gota is a pariah. We must get rid of him."

Rajapaksa's tenure was marked by policy U-turns. Critics say he has revoked more than 100 government decrees, earning him the moniker "Gazette Reverse".

He abandoned democratic reforms of the previous administration and made the presidency more powerful, but in the final months of his presidency agreed to return those powers to parliament.

Soon after coming to power he drastically cut taxes to win over his financial backers, a move partly blamed for Sri Lanka's dire economic crisis. Those taxes are now being raised.

Arguably his biggest policy blunder was the banning of agrochemicals in April last year. He reversed the ban six months later, but by then more than half of the crops had failed.

The government promised but failed to compensate millions of farmers affected under Rajapaksa's disastrous drive to become the world's first 100-percent organic farming nation.

As shortages of food and fuel gripped the country and prices soared, cities and towns across the country were dotted with protests calling on him to go.

During the pandemic his refusal to allow Muslims, the country's second-largest minority, to bury their Covid-19 dead according to Islamic rites and instead forcing cremations drew condemnation from the Islamic world as well as from rights groups.

Buddhist monks welcomed his stubborn refusal to allow Muslim burials, but the tables turned quickly: a year later, a shortage of gas forced Buddhists to bury their dead over their preferred cremations.

#GotaGoHome become a trending hash-tag on social media. After overrunning his official residence on Saturday, activists hung Rajapaksa's effigy in a symbolic gesture of what they wanted to do to him.