On 20 January 2015, Lungu contested the presidential by-election and beat his closest rival Hakainde Hichilema of the United Party for National Development by a narrow majority of just 27,757 votes (1.66%), with just 32.36% of the registered electorate participating. He was declared the winner by the Electoral Commission of Zambia on 24 January.