Uganda's President Yoweri Museveni has a clear lead in the presidential race following Thursday's vote, official preliminary results show.
But his main challenger, pop star-turned-politician Bobi Wine, said the tally was the result of the worst rigging in Ugandan electoral history.
Election monitors say confidence in the count has been damaged by an internet shutdown, now in its third day, according to the BBC.
Dozens of people were killed in the run-up to the election.
President Museveni, who has been in power for 35 years, is hoping for a sixth term.
The 76-year-old says he is standing for stability, while Bobi Wine, the stage name for 38-year-old Robert Kyagulanyi, says he represents the younger generation in one of the world's youngest countries.
With 49.1% of ballots counted, Mr Museveni has won 62.7% of the vote compared to Bobi Wine with 29.3%, the electoral commission says.
Election commission chief, Simon Byabakama, said the vote had been peaceful, and told Bobi Wine, who said some of his polling agents were arrested on Thursday, to make public the evidence for his fraud allegations.
The opposition candidate believes the internet shutdown is being used to block communication and as a way of compromising the vote.
As well as being unable to get online, people have been having trouble sending text messages.
"Several of our phone numbers, including mine and my wife's, have been switched off, have disconnected illegally," the Reuters news agency quoted him as saying.
"I will be happy to share the videos of all the fraud and irregularities as soon as the internet is restored."
The electoral commission says only two polling stations in the country reported major irregularities and voting was cancelled there.
BBC correspondents say there is tight security in the capital, Kampala, with soldiers and police patrolling the streets.
It has been quiet in the city on Friday and some businesses remain closed, the AFP news agency reports.
Security forces cracked down on gatherings ahead of the election and dozens were killed.
The government says the ban on gatherings was to prevent the spread of coronavirus while the opposition say it was a smokescreen for repression.
Bobi Wine and other opposition candidates have been arrested on several occasions.
Eleven candidates are contesting in the election. One of them is a woman, Nancy Kalembe.
18.1m people registered to vote.
Mr Museveni, who came to power on the back of an armed uprising in 1986, is standing as leader of the National Resistance Movement (NRM).
He has long been depicted to Ugandans as a liberator and peace bringer.
But he has managed to maintain his grip on power through a mixture of encouraging a personality cult, employing patronage, compromising independent institutions and sidelining opponents, says the BBC's Patience Atuhaire.
Bobi Wine is widely thought to be the strongest of the 10 opposition candidates in the presidential race.
The reggae star is known by his supporters as the ghetto president.
His party, the National Unity Platform (NUP), campaigns for basic needs like improving access to healthcare, education, clean water and justice.
Over the last two decades Bobi Wine's musical output has been filled with songs about these issues and they have inspired a fervent following.
He grew up in Kampala's Kamwokya slum where he went on to build his now world-famous recording studio.