Brazilian ex-president Luiz Inacio Lula da Silva walked free from jail Friday after a court ruling paved the way for the release of thousands of convicts.

The Supreme Court voted 6-5 in favor of scrapping mandatory imprisonment for convicted criminals after they lose their first appeal.

Instead, they remain free until they have exhausted the legal process.

Here is a list of key dates in the life of one of the world's most popular politicians.

- October 27, 1945: Lula is born to a poor farming family in Brazil's northeast. His family moves when he is seven to the state of Sao Paulo to escape hunger.

- 1975: He becomes president of the metal workers' union, having worked in that sector since the age of 14.

- 1978-80: At the height of the military dictatorship, Lula leads major strikes in the industrial suburbs and is jailed for a month for his role.

- 1980: Lula co-founds the leftist Workers Party (PT) and goes on to take part in the creation, in 1983, of the Unified Workers Central (CUT), which becomes Brazil's largest trade union federation.

- 1986: He is elected to Congress.

First leftist president

- 2003: Lula becomes Brazil's first leftist president, and the first to come from a working-class background, after winning the previous year's election. Under his social programs 29 million Brazilians escape poverty, although inequality remains. He is reelected in 2006 for a term ending in 2010.

- 2005: He removes top officials of the Workers Party over corruption scandals.

- 2016: The Supreme Court blocks his appointment as chief of staff to President Dilma Rousseff, his handpicked successor. She is then impeached in August after allegations of financial wrongdoing.

- July 2017: Lula is found guilty of receiving a bribe from a Brazilian construction company in return for contracts with state oil giant Petrobras. He is sentenced to nine and a half years behind bars.

- January 2018: He loses an appeal and his sentence which was increased to 12 years and one month.

- April 5, 2018: After losing an appeal to delay the start of his sentence, Lula is ordered to turn himself in within 24 hours. He defies the order but later agrees to comply.

- April 7, 2018: Shortly before midnight, Lula becomes an inmate at the federal police headquarters in Curitiba.

- August 15, 2018: Lula's Workers Party officially registers his presidential candidacy.

- August 31, 2018: A majority of Brazil's electoral court bars Lula from running in October's election.

- September 11, 2018: The Workers Party names Fernando Haddad as a substitute candidate for Lula.

- October 28, 2018: Far-right candidate Jair Bolsonaro is elected president, ending decades of center-left rule in Brazil and reducing Lula's chances of freedom.

- February 6, 2019: Lula is handed a near 13-year sentence for accepting renovation work by two construction companies on a farmhouse in exchange for ensuring they won contracts with Petrobras.

- April 7, 2019: Thousands rally to protest Lula's first year in prison.

- April 23, 2019: A Superior Court of Justice panel reduces Lula's sentence to eight years and 10 months on appeal.

- November 7, 2019: The Supreme Court overturns a rule requiring convicted criminals to go to jail after losing their first appeal, paving the way for Lula's release.

- November 8, 2019: Lula walks free from jail after a federal judge authorizes his release.

bur-amj/mdl