Brazil has taken a turn to the left as former president Luiz Inácio Lula da Silva beat far-right incumbent Jair Bolsonaro in the presidential election.
After a divisive campaign which saw two bitter rivals on opposite sides of the political spectrum go head to head, Lula won 50.9% of the votes.
It was enough to beat Jair Bolsonaro, whose supporters had been confident of victory.
But the division which this election has highlighted is unlikely to vanish.
It is a stunning comeback for a politician who could not run in the last presidential election in 2018 because he was in jail and banned from standing for office.
He had been found guilty of receiving a bribe from a Brazilian construction firm in return for contracts with Brazil’s state oil company Petrobras.
Lula spent 580 days in jail before his conviction was annulled and he returned to the political fray.
“They tried to bury me alive and here I am,” he said, kicking off his victory speech.
Opinion polls suggested from the start that he would win the election, but when his lead in the first round was much narrower than predicted, many Brazilians started to doubt their accuracy.
Jair Bolsonaro’s backers – encouraged by their candidate’s allegations that “the establishment” and the media were against him and therefore underplaying his support – had complete faith in his victory.
The left-wing leaders victory is likely to rankle with these Bolsonaro fans, who routinely label Lula “a thief” and argue that the annulment of his conviction does not mean he was innocent, just that the proper legal procedure was not followed.
And while Jair Bolsonaro has lost, lawmakers close to him won a majority in Congress, which means that Lula will face stiff opposition to his policies in the legislative body.
But Lula, who served two terms in office between January 2003 and December 2010, is no stranger to forging political alliances.
As his vice-presidential running mate he chose former rival Geraldo Alckmin, who ran against Lula in previous elections.
His strategy of creating a “unity” ticket seems to have paid off and drawn voters into the fold who may not have consider otherwise casting a ballot for his Workers’ Party.
In his victory speech, he struck a conciliatory tone, saying he would govern for all Brazilians and not just those who voted for him.
“This country needs peace and unity. This population doesn’t want to fight anymore,” he said.
Jair Bolsonaro has yet to concede. The campaign had in part been so tense because the far-right president had cast doubts – without offering any evidence – on the reliability of Brazil’s electronic voting system.
This fomented fears he might not accept the result if it went against him.
A day before the second round, however, he stated that: “There is not the slightest doubt. Whoever has more votes, takes it [the election]. That’s what democracy is about.”