Opposition candidate Raila Odinga claimed the vote was rigged
Kenya's president Uhuru Kenyatta has won a second term but opposition candidate Raila Odinga claims the vote was rigged.
The country's election commission says Kenyatta won Tuesday's election with 54.27% of the vote, calling it "credible, fair and peaceful".
Opposition leader Raila Odinga took 44.74%, said commission chairman Wafula Chebukati.
"Having fulfilled the requirement by law... I therefore wish to declare Uhuru Kenyatta... as President-elect," said Mr Chebukati.
The opposition called the vote a "charade" and said going to court to challenge it is not an option, but did not state what measures it would take.
The newly-elected president called for unity, saying "there is no need for violence", and added that he wanted to work with Mr Odinga.
"I reach out to you. I reach out to all your supporters. To our brothers, our worthy competitors, we are not enemies, we are all citizens of the same republic," he said.
President Kenyatta (55) is a wealthy businessman and the son of Kenya's first president.
Opposition leader Mr Odinga is a left-wing former political prisoner who lost the 2013 vote to Kenyatta and took allegations of vote rigging to the Supreme Court, which rejected his case.
Kenyan police fired tear gas to contain protests which broke out minutes after the winner was declared.