A breakthrough deal on the transfer of the controversial US-run Bagram prison and other detention facilities in Afghanistan to Afghan authorities will be signed Friday, officials said.
The handover of the prison -- sometimes called Afghanistan's Guantanamo Bay -- has been a key sticking point in talks between the United States and the Afghan government over the signing of a long-term strategic partnership treaty.
Karzai has repeatedly demanded -- in the name of Afghan sovereignty -- that the prison be transferred before he signs any deal governing Afghan-US relations after NATO combat troops pull out in 2014.
Human rights campaigners have regularly criticised the prison, saying it fails to comply with international norms as some inmates are victims of arbitrary detention without trial or knowledge of the charges against them.
"There is expected to be a signing of a memorandum of understanding to transfer US detention facilities to Afghan control," a Western official told AFP on condition of anonymity.
The deal was confirmed by President Hamid Karzai's deputy spokesman, Siamak Hirawi, who said the handover process would be completed within three months.
The memorandum of understanding is expected to be signed by Defence Minister General Abdul Rahim Wardak and the US commander in Afghanistan, General John Allen, at a ceremony later Friday.
The prison at Bagram, a military base north of Kabul, holds rebel fighters detained by US-led NATO forces in their 10-year war against a Taliban-led insurgency trying to topple Karzai's government.
Bagram base was the site of the burning of Korans last month which ignited days of violent anti-US protests in which some 40 people died, plunging relations between foreign forces and their Afghan allies to an all-time low.
The Korans, which were sent to an incinerator pit, had reportedly been seized from prisoners who were suspected of using them to pass secret messages.
News of the deal came shortly after Karzai and US President Barack Obama spoke by video conference Thursday.
"President Karzai updated the president on the security situation in Afghanistan, which has calmed since the events of recent weeks," said White House spokesman Jay Carney.
Obama and Karzai also discussed reconciliation talks with the Taliban and the planned transition of security from NATO to Afghan control, Carney said.
"The leaders noted progress toward concluding a strategic partnership that reinforces Afghan sovereignty while addressing the practical requirements of transition."
A US official has told AFP that any arrangement on a long-term partnership would probably involve "shared facilities" after 2014 in order to help Afghan forces with intelligence, air power and logistics.
In early January, Karzai gave the United States a one-month deadline to hand over the prison, later extending it to March 10.
The prison was built within the sprawling US military base at Bagram after the 2001 US-led invasion toppled the Taliban, and in the early years gained a reputation for extra-judicial brutality.
A new prison called the Detention Facility in Parwan, with capacity for more than 1,000 inmates, replaced the 650-detainee facility at Bagram in 2009, but Afghan authorities still use the old name.