He was greeted outside Bangkok’s Klong Prem prison by family members, including his daughter and protege, former prime minister Paetongtarn Shinawatra.

Thaksin’s party Pheu Thai’s insistence that from now on he will remain in the background could not stop feverish media speculation over what role he might still play in Thai politics.

This is hardly surprising.

From the moment he swept to power in January 2001 Thaksin, a brash, self-made billionaire, has sought to reshape his country, winning devoted supporters and bitter opponents in equal measure. His parties kept winning elections, even after he was deposed by a coup in September 2006, but fear of his vaunting ambition in the powerful royalist establishment led to multiple court rulings against his allies, years of violent street clashes, and another coup in 2014.

Yet he refused to step back. He continued to run his party from abroad, and, after an apparent “grand bargain”, his conservative opponents allowed him to come home in 2023, to direct it once it was back in government again.

His continued popularity was evident outside the prison where his supporters had gathered.

One of them – Maysa Lombuarot – had driven 700km (435 miles) to see him released.

“Today I brought him 20kg of lychees. I know he likes them. Now that he’s free, I want him to eat something good,” she told the BBC, adding that she hoped he would continue his political career.

“I want him to help the country, to help the people who are suffering so much right now… only he can deliver what he promised,” she said.

And Thaksin does seem incapable of taking a back seat, whatever he may say about spending more time with his grandchildren.