Supporters of the surprise Democratic Republic of Congo presidential winner have celebrated in the capital as the rival opposition candidate denounced the result as fraudulent.

“Today I am happy,” Felix Tshisekedi told supporters. “Happy for the people of Congo. Everyone is celebrating that there is peace. No one could imagine the scenario where an opposition candidate could be victorious.”

But Martin Fayulu alleged the results had been rigged, saying outgoing President Joseph Kabila made a backroom deal with Mr Tshisekedi.

DR Congo’s Catholic church said the official election results did not tally with the outcome that its 40,000 observers compiled in recording results posted at all polling stations.

Its secretary general, Donatien Nshole, refused to say who won the election according to its findings but diplomats briefed on the results said they indicated Mr Fayulu won easily.

Mr Nshole urged all Congolese to remain peaceful and said those who challenge the official results should do so within the legal framework and without violence.

Opposition candidate Martin Fayulu wipes his face before speaking to the press in Kinshasa (Jerome Delay/AP)

Now Congo and the world face the uncomfortable choice of accepting what could be the country’s first peaceful, democratic transfer of power or raising a protest that could lead to more violence in the nation.

Mr Tshisekedi, who received 38% of the vote according to the electoral commission’s results, had not been widely considered the leading candidate and is relatively untested.

Long in the shadow of his father, the late opposition leader Etienne, Mr Tshisekedi startled DR Congo last year by breaking away from the unified opposition candidate Mr Fayulu to stand on his own.

Mr Fayulu quickly called the announced election results “rigged, fabricated and invented” and said they do “not reflect the truth of the ballots”. He called on the Congolese people to “rise as one man to protect victory”.

A police spokesman said three people were killed amid demonstrations against the election results.

Pierrot Mwanamputu said that a youth in the city of Kikwit caused violence that led to the deaths of two civilians and the wife of a police officer.

The spokesman said 17 police officers were wounded and some shops were vandalised but the vast country of some 80 million people was largely calm after the results.

Mr Fayulu, a former Exxon manager and Kinshasa lawmaker, received 34% of the vote in the official results.

“How long are we going to negotiate results?” he asked. “In 2006, Jean-Pierre Bemba’s victory was stolen. In 2011, Etienne Tshisekedi’s victory was stolen. In 2018, victory won’t be stolen from Martin Fayulu.”

Even before the announcement, some observers suggested that Mr Kabila’s government made a deal with Mr Tshisekedi as hopes faded for ruling party candidate Emmanuel Ramazani Shadary, who received just 23% of the official results.

DR Congo’s constitutional court has 14 days to validate the results.

France’s foreign minister Jean-Yves Le Drian bluntly cast doubt on the official results, saying they did not match the findings of the Catholic Church’s observers.

The United Nations secretary-general merely “took note” of the results and urged stability and peace.

The delayed results, nearly two weeks after the December 30 vote, came after international pressure to announce an outcome that reflected the will of the people. The United States threatened sanctions against officials who rigged the vote.

The largely peaceful election was marred by the malfunctioning of many voting machines that DR Congo used for the first time.

Residents celebrate in Kinshasa (Jerome Delay/AP)

Dozens of polling centres opened hours late as materials went missing. And in a last-minute decision, some 1 million of the country’s 40 million voters were barred from participating, with the electoral commission blaming a deadly Ebola virus outbreak.

Defiantly, tens of thousands of voters in one of the barred communities held their own unofficial ballot on election day, and Mr Fayulu won easily.

DR Congo’s government cut internet services the day after the vote to prevent speculation on social media. As the electoral commission met this week, anti-riot police moved into place outside.

Mr Kabila has ruled since 2001 in the troubled nation rich in the minerals key to smartphones around the world and has amassed vast wealth. He is barred from serving three consecutive terms, but during more than two years of election delays many Congolese feared he would find a way to stay in office.

Now DR Congo faces a new leader who is little known after spending many years in Belgium and standing behind his outspoken father. The 56-year-old took over as head of DR Congo’s most prominent opposition party in early 2018, a year after his father’s death.

Happy Tshsekedi supporters in Kinshasa, a lively opposition stronghold, said they were delighted by their candidate’s win and happy to see Mr Kabila step down.

“This is the coronation of a lifetime,” said the deputy secretary-general of Tshisekedi’s party, Rubens Mikindo. “This is the beginning of national reconciliation.”