The electoral commission declared deputy president William Ruto winner with 50.49% of the vote and Odinga second with 48.85%.