It said that President Museveni had won 60.75% of the vote, while his main opponent Kizza Besigye had taken 35%.
President Museveni will now serve another five years in office, having already been in power for 30 years.
EU observers have criticised the poll, saying the governing party has created an “intimidating atmosphere” and the opposition alleges vote rigging.
Mr Besigye has been under house arrest since Friday on suspicion he was planning to publish his own results, breaking electoral laws, police said.
The election has been marred by sporadic violence and opposition allegations of electoral fraud, with social media sites and messaging apps blocked.
“Voters actively participated in the campaign events and expressed a remarkable determination while waiting for the long hours on the election day to cast their ballots,” said EU Chief Observer Eduard Kukan.
“However, the [governing] National Resistance Movement’s domination of the political landscape distorted the fairness of the campaign.”
The main opposition challenger Kizza Besigye (L) was arrested on Friday
Police were surrounding his home on Saturday
Mr Besigye went further, telling AFP news agency that he was detained when on the verge of busting an alleged police-run election rigging operation.
He told the agency he had “very reliable information, corroborated information that there was a house in a suburb of the city… where the operation of rigging the elections is centred.”
It is the fourth time Mr Besigye, candidate for the opposition Forum for Democratic Change, has taken on President Museveni.
The two men were once allies, with Mr Besigye serving Mr Museveni as his personal doctor when they were guerrilla fighters.
Mr Museveni seized power in 1986 and is credited with restoring stability to Uganda. However, critics say he has become increasingly authoritarian.
The next closest challenger to Mr Museveni, former Prime Minister Amama Mbabazi, is also reportedly under house arrest.
- Kizza Besigye, 59, a veteran opposition leader. He has lost the last three elections
- Amama Mbabazi, 67, former ally of President Museveni and once prime minister – also served as defence, security and justice ministers
- Yoweri Museveni, 71, in power since winning a five-year guerrilla war in 1986 – one of Africa’s longest-serving leaders. His final term was meant to end in 2006, but in 2005 he won a campaign to lift the constitutional term limits