Edgar Lungu has been sworn in as Zambia's sixth president after narrowly winning a vote rejected by the opposition.
The election commission said Lungu, of the ruling Patriotic Front, won 48.3 percent of the vote. His rival, Hakainde Hichilema of the United Party for National Development, finished second with 46.7 percent.
Hichilema alleges the election, which ended Saturday, was "stolen" and does not reflect the will of the people of Zambia. Voting began on January 20 but was extended because of heavy rains in some areas.
The election was triggered by the death in October of President Michael Sata. Lungu will serve out Mr. Sata's term until new elections next year.
Lungu, who heads Zambia's justice and defense ministries, said he wants to complete economic development projects initiated by Sata.
Voter turnout was light at around 32 percent, blamed in part on the bad weather. Observers told the Reuters news agency the election was fair.
Sata's vice president, Guy Scott, had been serving as acting president. Scott was not eligible to run for the top office because his parents were not born in Zambia. He is the son of Scottish parents.
Poll observers from the Electoral Institute for Sustainable Democracy in Africa (EISA) say they were impressed with the Electoral Commission of Zambia’s (ECZ) work in administering a transparent and credible presidential by-election.
Denis Kadima, deputy head of EISA’s election monitoring team, said Zambian voters were peaceful and orderly, allaying fears that violence between rival parties could undermine the election.
“Our mission is quite impressed with the performance of the Electoral Commission of Zambia, because this was a snap election and they had to put the machinery in place and run the election within 90 days from the death of the late president," Kadima said.
"And they performed very well in terms of managing the logistics, despite the rainy season, which actually added to their challenges in addition to the short notice.”
He also praised the commission’s competence and professionalism. Kadima said the ECZ effectively coordinated political parties and poll monitors in a bid to ensure transparency.
He said Zambian voters were well-informed about the election process.