Release comes after Supreme Court ruling ended mandatory imprisonment of convicts after they lose their first appeal.

Former Brazilian President Luiz Inacio Lula da Silva walked out of prison on Friday after his release was ordered by a judge.

The order came a day after the country’s Supreme Court overturned a law that required the imprisonment of convicts after they lose their first appeal.

As he walked out of jail, Lula raised a defiant fist of victory in the air to the cheers of a crowd of supporters and members of his Workers Party who waved red flags and held “Free Lula” banners.

He called for a rally on Saturday in Sao Paulo before he planned to embark on a national tour, he said.

Lula was jailed in 2018 for eight years and 10 months after he was found guilty of taking bribes from engineering firms in return for government contracts.

In his first speech to supporters waiting for him to walk free, Lula pledged to fight to establish his innocence and excoriated what he called the “rotten side of the judicial system” for “working to criminalise the left”.

Former Brazilian President Luiz Inacio Lula da Silva speaks after leaving the Federal Police Headquarters [Henry Milleo/AFP]

Thursday’s controversial Supreme Court decision could benefit dozens of other high-profile prisoners and thousands of other convicts.

Analysts say the prospect of serving immediate prison time after losing a first appeal encouraged suspects to negotiate plea deals with prosecutors, providing them information that helped unravel the biggest corruption scheme in Brazil’s history.

The law had contributed to the success of Brazil‘s biggest corruption investigation, the so-called “Car Wash” operation that put dozens of company executives and politicians in jail for bribes and kickbacks.

The Car Wash prosecutors said the ruling would make their job harder and favour impunity because of Brazil’s “excessive” appeal processes. They said in a statement that the court’s decision was out of sync with a country that wants an end to corruption.

Brazil’s Justice Minister Sergio Moro said on Friday that the Supreme Court ruling should be respected.

Moro, who was the Car Wash trial’s judge who sentenced Lula before being appointed justice minister by President Jair Bolsonaro‘s government, warned before the court’s decision that overturning the rule would be a big setback for the fight against corruption.

Investors were jolted by the prospect of Lula returning to the political stage and uniting opposition to the market-friendly government, although he is barred from running in upcoming elections.

Brazil’s currency and benchmark Bovespa stock index both fell 1.8 percent on Friday, weighed down first by Thursday’s Supreme Court ruling and deepening losses after the formal court order letting him go.

‘Not electable’

Lula, Brazil’s first working-class president, served as the country’s leader between 2003 and 2010. He left office with sky-high popularity ratings thanks to social policies that raised millions from poverty. He was favoured to win the 2018 presidential election, but his imprisonment barred him from running.

His critics accuse him of ruining the country by allowing corruption to flourish.

His release will likely heighten tensions in a polarised country that elected far-right President Bolsonaro last year.

Lula is free to engage in politics, but will not be eligible under Brazil’s Clean Record law to seek elected office for eight years after his first conviction, which was in June 2017.

“Lula is not electable, but that is not needed for him to take centre stage,” said political analyst Alberto Almeida.

“He can draw more politicians from the centre and end up as a dealmaker for his party’s candidate in the 2022 presidential elections.”