Former rebel Gustavo Petro is set to be Colombia's first leftist president after voters handed him a slim victory in Sunday's runoff election against Rodolfo Hernández, a political outsider and populist. 

Petro had garnered 50.47% of the votes to Hernandez's 47.25% on Sunday evening, according to preliminary results released by election authorities. 

"Today is a day of celebration for the people. Let them celebrate the first popular victory," Petro, a current senator and former mayor of Bogota, tweeted after the results came in. "May so many sufferings be cushioned in the joy that today floods the heart of the Homeland."

Colombia presidential election

Former rebel Gustavo Petro, left, his wife Veronica Alcocer, back center, and his running mate Francia Marquez, celebrate before supporters after winning a runoff presidential election in Bogota, Colombia, Sunday, June 19, 2022.  (AP Photo/Fernando Vergara)

The former guerilla's victory is a sign of rising discontent in Colombia and the rest of Latin America, as it comes after Chile, Peru, and Honduras elected leftist presidents in 2021. 

BIDEN TOUTS WESTERN HEMISPHERE ‘OPPORTUNITIES,’ DEMOCRACIES AT SUMMIT THAT EXCLUDED LATIN AMERICAN DICTATORS

Nearly half of Colombians say that their local economy is getting worse, while 80% say corruption is widespread in the government, according to a recent Gallup poll. 

The Colombian presidential candidate for the Historic Pact coalition, Gustavo Petro, waves as he arrives at a polling station to cast his vote during the presidential election, in Bogota on May 29, 2022.

The Colombian presidential candidate for the Historic Pact coalition, Gustavo Petro, waves as he arrives at a polling station to cast his vote during the presidential election, in Bogota on May 29, 2022. (JUAN BARRETO/AFP via Getty Images)

Petro, who was jailed in the 1980s for his involvement in the defunct M-19 movement, promised a suite of economic reforms during his campaign, including higher taxes, more government spending, and changes to the country's pension system. 

While voters elected Petro on his progressive platform, he will have trouble delivering on his promises due to Colombia's fragmented Congress. 

McCAUL: US MUST ‘WAKE UP’ AND INVEST IN LATIN AMERICA TO GAIN EDGE OVER CHINA

Hernández, a millionaire real estate magnate who ran an unconventional campaign on TikTok and other social media platforms, conceded on Sunday evening. 

Colombians celebrate Gustavo Petro's victory

Supporters of presidential candidate of the Historical Pact coalition, Gustavo Petro, celebrate after he won a runoff presidential election in Cali, Colombia, Sunday, June 19, 2022.  (AP Photo/Andres Quintero)

"I accept the result, as it should be, if we want our institutions to be firm," Hernández said in a video. "I sincerely hope that this decision is beneficial for everyone."

CLICK HERE TO GET THE FOX NEWS APP

Francia Marquez, Petro's running mate, will become Colombia's first Afro-Colombian female vice president. 

The Associated Press contributed to this report.