Kenya's election took an ominous turn on Wednesday as violent protests erupted in the capital and elsewhere after opposition leader Raila Odinga alleged fraud, saying hackers used the identity of a murdered official to infiltrate the database of the country's election commission and manipulate results.
Soon after Mr. Odinga spoke on television, angry protesters in slums of Nairobi and the opposition stronghold of Kisumu in the southwest burned tires, set up roadblocks, and clashed with police, witnesses said. Kenyan police opened fire on people protesting election results earlier Wednesday in another opposition stronghold, killing one person. The shooting happened in South Mugirango constituency in Kisii county, said Leonard Katana, a regional police commander.
With results from almost all of the polling stations counted, President Uhuru Kenyatta was shown with a wide lead over Odinga in his bid for a second term.
Many parts of Kenya, East Africa's commercial hub, were calm a day after the elections for president and more than 1,800 other posts down to the county level. But the violence stirred memories of the unrest following the 2007 vote in which more than 1,000 people were killed. Odinga lost that election; he also lost the 2013 vote to Mr. Kenyatta and took allegations of vote-tampering to the Supreme Court, which rejected his case.
Odinga, a former prime minister, blamed Kenyatta's Jubilee Party for the alleged hacking of the election database.
"The fraud Jubilee has perpetuated on Kenyans surpasses any level of voter theft in our country's history. This time we caught them," he tweeted.
Odinga claimed that hackers used the identity of Christopher Msando, an election official in charge of managing information technology systems. On July 31, officials announced that Mr. Msando had been tortured and killed, alarming Kenyans who feared a recurrence of political violence that has been fueled by ethnic divisions.
Msando had sought to reassure voters that election results would not be tampered with.
Rafael Tuju, a top official in Kenyatta's party, said the opposition's claims were unfounded.
Kenya's election commission said it will investigate Odinga's allegations. "For now, I cannot say whether or not the system has been hacked," said Wafula Chebukati, the commission chairman.
Kenyatta was leading with 54.34 percent and Odinga had 44.78 percent after votes at nearly 39,000 of the 40,883 polling stations were counted, according to the election commission.
In the city of Kisumu, police used tear gas and shot at protesters who were upset after Odinga's fraud allegations, said demonstrator Sebastian Omolo.
"He is not accepting the results and that is why we are on the streets, but police have started shooting," Mr. Omolo said.
Kisumu shopkeeper Festus Odhiambo said he was praying for peace even as protesters blocked roads into city slums with bonfires and boulders.
The western port city on Lake Victoria has been a flashpoint in past elections.
Kenya's interior minister, Fred Matiangi, warned against the use of social media to stoke tensions. Officials have said it was unlikely they would shut down the internet but said they might shut down some social media if necessary to calm hate speech and incitement.
"We assure Kenyans and all residents, the country is safe and I urge everyone to go on freely with their daily chores," Mr. Matiangi said.
Odinga's running mate, Kalonzo Musyoka, also called for restraint as the fraud allegations are investigated.
"There may come a time we may have to call you to action," Mr. Musyoka said. "But for now it is important we be strategic as we delve deep into this matter."
This story was reported by The Associated Press.