President Obama has sent a letter to Afghanistan counterpart Hamid Karzai apologizing for a recent incident of Quran burning at a U.S. airbase there.

"I wish to express my deep regret for the reported incident," Obama wrote in the letter delivered to Karzai today, and released by the Afghanistan government. "I extend to you and the Afghan people my sincere apologies."

"The error was inadvertent," the letter added. "I assure you that we will take the appropriate steps to avoid any recurrence, to include holding accountable those responsible."

The burning incident triggered anti-U.S. riots that have killed at least 14 people, including two American soldiers. Violence continued on Thursday.

National security adviser spokesman Tommy Vietor confirmed delivery of the letter to Karzai.

"Following up on their February 20 phone call, the president sent a letter to President Karzai to continue their discussion on a range of issues related to our long-term partnership," Vietor said.

"In the letter, delivered by Ambassador (Ryan) Crocker this afternoon in Kabul, the president also expressed our regret and apologies over the incident in which religious materials were unintentionally mishandled at Bagram Airbase," Vietor added.

The Quran apology is part of "a lengthy, three-page letter on a host of issues, several sentences of which relate to this matter," said White House spokesman Jay Carney.

The topics included "reconciliation" and "the trilateral talks that we had with Pakistan last week in Islamabad," Carney said. "(The president) also expressed his apology for the inadvertent burning of religious materials by American personnel in Afghanistan.

"It is wholly appropriate given the understandable sensitivities to this issue. His primary concern as commander in chief is the safety of American men and women in Afghanistan, of our military and civilian personnel there," Carney said. "It's absolutely the right thing to do."

From the AFP wire service: