Jubilee Party candidate in the Kibra by-election McDonald Mariga has conceded defeat to his ODM rival Bernard Okoth.
In a video clip, Mr Mariga called Mr Okoth to congratulate him for his victory.
He said he was happy that the contest was carried out peacefully and that they will continue being friends.
Mr Mariga conceded defeat when the Independent Electoral and Boundaries Commission (IEBC) figures from 40 out of 183 polling stations showed he was trailing Mr Okoth who had garnered 4,988 votes with 2,106.
Amani National Congress candidate Mr Eliud Owalo had 1,258 votes.
Report by Collins Omulo and Cecil Odongo