A former leader of Madagascar, Andry Rajoelina, has won the country's presidential run-off vote, electoral authorities say.
He won nearly 56% to defeat another former president, Marc Ravalomanana.
Both candidates had previously promised to accept the result.
However Mr Ravalomanana - who was ousted by Mr Rajoelina in a coup almost 10 years ago - has since made allegations of what he calls "massive fraud".
Mr Ravalomanana did not attend the electoral commission's results announcement, made amid high security in the capital Antananarivo.
The constitutional court now has nine days to decide whether to confirm the commission's results.
During the first round of the election, Mr Rajoelina took 39% of the vote and Mr Ravalomanana 35%.
Both candidates had promised to boost the economy in a country where 75% of the population live in poverty.
Outgoing president Hery Rajaonarimampianina was eliminated in the first round, getting just 9% of the vote.
Mr Rajoelina and Mr Ravalomanana are both wealthy men, fuelling claims by civil society groups that they used their time in office to enrich themselves - which they deny.
The two men were barred from entering the 2013 presidential race because the international community feared it would reignite a political crisis.
A history of instability
At the end of 2001, self-made millionaire Mr Ravalomanana won a disputed poll, which led to a seven-month crisis, with the defeated candidate Didier Ratsiraka refusing to step down.
In 2009, after weeks of protests, media mogul Mr Rajoelina ousted Mr Ravalomanana in a power grab that was backed by the army.
This year, President Rajaonarimampianina faced protests over an electoral law that was said to favour him.
The issue sparked protests that quickly escalated to political paralysis which ended in a compromise after the military threatened a takeover.
A unity government took over to pave way for the elections.