Madagascar's Independent National Election Commission (INEC) declared former president Andry Rajoelina as the winner in the second round of presidential election on Thursday.
According to the initial results published by the INEC, Rajoelina won some 55.66 percent of the votes while his sole rival in the race, Marc Ravalomanana, got about 44.34 percent votes.
The results, announced under high security, may be contested after Ravalomanana claimed fraud.
Rajoelina, 44, sat in the front row among the 200 guests in the room where the electoral commission announced the results.
A seat next to him, apparently reserved for Ravalomanana, was empty, according to an AFP journalist.
Presidential candidate Andry Rajoelina attends the results proclamation ceremony at the INEC (Independent National Electoral Commission) in Antananarivo, December 27, 2018. /VCG Photo
"It's unfortunate that the other candidate is not here," the president of the electoral commission, Hery Rakotomanana, said.
The electoral commission chief said "efforts were made to respond" to concerns raised by both candidates, which included a review of the counting software.
The two-round election was plagued by mutual accusations of vote-rigging.
Heavily-armed police patrolled the area around the electoral commission offices where the results were being announced.
Rajoelina and Ravalomanana are former presidents and long-time rivals who have fought a fiercely personal duel for power.
'Vote-rigging'
The European Union (EU) election observers have said they had not seen evidence of wrongdoing in the vote in which about five million ballots were cast.
Ravalomanana, a 69-year-old former milkman who built a business empire, had on Sunday urged supporters to protest what he called "injustice and a violation of their right to vote."
Elected president in 2002, he was forced to resign seven years later following protests fueled by Rajoelina, who had been elected mayor of the capital Antananarivo.
This picture shows an inside view of the headquarters of Andry Rajoelina, in Antananarivo, December 27, 2018. /VCG Photo
Madagascar presidential candidate Marc Ravalomanana and his wife Lalao Ravalomanana address the media after casting his ballot during the presidential election at a polling center in Faravohitra district, Antananarivo, Madagascar, December 19, 2018. /VCG Photoā€¨
Rajoelina was then installed by the army and ruled until 2014.
He is a former events planner and successful entrepreneur.
The two adversaries came a close first and second in the preliminary election in November, with Rajoelina garnering 39 percent compared with 35 percent for Ravalomanana.
The two candidates were both banned from running in the 2013 election as part of an agreement to end recurring crises that have rocked Madagascar since independence from France in 1960.
Outgoing president Hery Rajaonarimampianina was eliminated in the first round after winning only nine percent.
Just under half or 48.09 percent of the eligible 10 million voters bothered to cast their votes, slightly lower than in the first round which saw around 55 percent turning out.
The country's High Constitutional Court has nine days to officially declare the name of the new leader after examining any petitions.
Madagascar is well known for its vanilla and precious redwood, yet is one of the world's poorest nations, according to World Bank data, with 76 percent of people living in extreme poverty.