Brazil's then-president, Luiz Inacio Lula da Silva, reviews an honor guard during a reception at Havana's Revolution Palace on Jan. 15, 2008. (Claudia Daut/Reuters)

— Former president Luiz Inacio Lula da Silva was convicted Wednesday of corruption and money laundering and sentenced to more than nine years in prison, a stunning blow to a man once hailed across the hemisphere as an innovative leftist leader.

The verdict is the highest profile conviction to come from Brazil’s Operation Car Wash, a massive corruption inquiry that has shaken the country’s political elite and created a leadership crisis.

The landmark decision marks the first conviction of the former president, widely known as Lula. He also faces four other corruption charges. The verdict represents a major setback for the popular leader’s political aspirations. His lawyers have already said he is planning to appeal, a process that could take a year and a half. He is expected to remain free while the case winds its way through the courts.

“No matter how important you are, no one is above the law,” Judge Sergio Moro said in announcing his verdict.

Lula, 71, has proclaimed his innocence and called the trial a witch hunt. The former president, who presided over Brazil’s government from 2003 to 2010, was found guilty of receiving $1.1 million in favors from a construction company.

Moro is one of the main protagonists in Operation Car Wash. Over the past three years, the investigation has traced corruption from a Brasilia gas station to the highest echelons of the government, and uncovered a complex kickback scheme in which politicians traded political favors for donations.

Brazil’s current president, Michel Temer, along with more than half his cabinet, a third of the Senate and dozens of representatives are being investigated as part of the probe.

On Wednesday, supporters of Operation Car Wash lined up outside the courtroom in southern Brazil where the verdict was announced, holding flowers for Moro and waving Brazilian flags. In Sao Paulo, fireworks sounded from the city’s main thoroughfare, Avenida Paulista. Supporters of Lula’s Workers’ Party, meanwhile, called for protests nationwide.

Lula was found guilty of charges that he accepted the use of a beach apartment — and free renovation work on the home — from the engineering company OAS SA in return for helping to arrange lucrative contracts with state oil company Petrobras. Lula’s defense says that the apartment belonged to the construction firm and that he visited it only once.

Gleisi Hoffmann, the president of the Workers’ Party, described the verdict as politically motivated and baseless. “This is an attack on democracy,” she said. “Where is your proof, Sergio Moro? Show us your proof.”

Lula, a former union organizer with a fourth-grade education, won fame as a spokesman for Brazil’s neglected poor. A co-founder of the Workers’ Party, he led the country as it rode a commodities boom and became a darling of investors. But he also introduced welfare policies that helped lift 36 million people out of poverty. President Obama once called him “the most popular politician on Earth.” Lula left office with an approval rate of more than 80 percent.

“All these things coming together presented a perfect sunny day, and Lula was at the helm. It is only natural that many of these positive things were attributed to his policies, but in reality, the enduring legacy of his time is the realization that the dream is over,” said Marcos Troyjo, co-director of the BRICLab at Columbia University, which studies Brazil, China, India and Russia.

As the commodities boom went bust, Brazil sunk into its worst recession on record, and the Workers’ Party lost support. The country’s leftists fell into disarray as Lula’s successor, Dilma Rousseff, was impeached in 2016 for mismanaging the country’s budget.

The left’s hopes for revival rested on the shoulders of the same man who led the party to international prominence. Lula was widely expected to run for reelection in 2018 and a June poll showed that he could beat prospective opponents by margins of nearly 20 percent. If he is found guilty by the appeals court before the election, though, he will not be permitted to run for president.

“These accusations and condemnations are tarnishing the image of Lula as a beloved leader at home and abroad,” said Alexandre Bandeira, a political consultant in Brasilia. “But Lula’s decay may open up space for new leadership not just in the [Workers’ Party], but through more moderate central-left parties. It creates an even greater opportunity for the reconstruction of the left.”