BRASILIA (Reuters) - Former Brazilian leader Luiz Inacio Lula da Silva, a top contender to win next year’s presidential election, was convicted on corruption charges on Wednesday and sentenced to nearly 10 years in prison.

The ruling marked a stunning fall for Lula, one of the country’s most popular politicians, and a serious blow to his chances of a political comeback. The former union leader, who won global praise for policies to reduce stinging inequality in Brazil, faces four more corruption trials and will remain free on appeal.

The verdict represented the highest-profile conviction yet in a sweeping corruption investigation that for over three years has rattled Brazil, revealing a sprawling system of graft at top levels of business and government.

Judge Sergio Moro found Lula, 71, guilty of accepting 3.7 million reais ($1.2 million) worth of bribes from engineering firm OAS SA, the amount of money prosecutors said the company spent refurbishing a beach apartment for Lula in return for his help winning contracts with state oil company Petroleo Brasileiro PETR4.SA.

Federal prosecutors have accused Lula, Brazil’s first working-class president from 2003 to 2011, of masterminding a long-running corruption scheme that was uncovered in a probe into kickbacks around Petrobras.

Lula’s legal team said in an emailed statement that he was innocent and they would appeal.

“For over three years, Lula has been subject to a politically motivated investigation,” they wrote. “No credible evidence of guilt has been produced, and overwhelming proof of his innocence blatantly ignored.”

Lula’s lawyer Cristiano Martins has repeatedly accused judge Moro of being biased against his client, which Moro strongly denies.

Moro wrote in his ruling that he “took no personal satisfaction in this conviction, quite to the contrary.”

“It’s lamentable that a president of the republic is criminally convicted,” Moro said. “No matter how important you are, no one is above the law.”

The Brazilian real BRBY extended gains following the decision and reached its strongest in two months. The benchmark Bovespa stock index .BVSP rose to a session high. Investors fear that another Lula presidency would mean a return to more state-directed and less business friendly economic policies.

“POWER VACUUM ON LEFT”

Lula would be barred from office if his guilty verdict is upheld by an appeals court, which is expected to take at least eight months to rule.

Slideshow ( 16 images )

If he cannot run, political analysts say Brazil’s left would be thrown into disarray, forced to rebuild and somehow find a leader who can emerge from the immense shadow that Lula has cast on Brazilian politics for three decades.

“Lula’s absence opens a gaping hole in the political scene, it creates an enormous power vacuum on the left,” said Claudio Couto, a political scientist at the Getulio Vargas Foundation, a top university. “We have now entered a situation of extreme political tension, even beyond the chaos we have been living for the last year.”

Couto said he expected Lula’s guilty verdict to be upheld by the appeals court. That would leave the 2018 presidential race wide open and raise chances of a victory by a political outsider, given most known contenders are also ensnared in Brazil’s corruption investigations.

Slideshow ( 16 images )

BOOM TO BUST

Lula’s two-terms were marked by a commodity boom that momentarily made Brazil one of the world’s fastest-growing economies. His ambitious foreign policies, aligning Brazil with other big developing nations, raised the country’s profile on the global stage.

With Lula’s swagger setting the tone, Brazil sought to shrug off northern economic and political hegemony and engage in global problems, like Middle East peace and the standoff over Iran’s nuclear program.

Former U.S. President Barack Obama once labeled him the most popular politician on earth.

But upon leaving office and managing to get his hand-selected successor Dilma Rousseff elected, Brazil’s economy soured, with the nation just now beginning to emerge from its worst recession on record.

Rousseff was impeached last year for breaking budgetary rules. She and her backers say her ouster was actually a ‘coup’ orchestrated by her vice president and now President Michel Temer, who himself faces corruption charges.

During his trial, Lula gave five hours of fiery and defiant defense, proclaiming his innocence and saying that it was politics and not the pilfering of public funds that put him on trial.

“But what is happening is not getting me down, just motivating me to go out and talk more,” Lula said in his testimony. “I will keep fighting.”

($1 = 3.22 reais)