The comments on Sunday come a day before US President George Bush and Afghan President Hamid Karzai are to meet at the White House.
"Such abuses are utterly unacceptable and are an affront to everything the international community stands for in Afghanistan," Jean Arnault, UN special representative in Afghanistan, said in a strongly worded statement.
Two Afghan prisoners held in a US-run prison at Bagram Airbase were tortured to death by American soldiers, The New York Times reported on Friday, citing a leaked 2000-page file on the US Army's criminal investigation of the case.
The two men died in 2002 after being kicked, beaten and hung from their wrists on the ceiling of their cells in what the paper described as a wider pattern of abuse by young and poorly trained soldiers that bore hallmarks of the Abu Ghraib scandal in Iraq.
The Afghan leader publicly expressed his shock at the alleged abuse before his trip to Washington, where he will meet with Bush to discuss the allegations as well as anti-US riots that swept Afghanistan earlier this month, killing at least 15.
Hours before he left Kabul, the US-backed president also called for greater Afghan control of US military operations.
Arnault echoed Karzai's call for "the punishment of all those involved in these inexcusable crimes".
The UN called for firm guarantees that such abuses would not be committed again, and renewed requests for access to prisons and detention facilities by the Afghan Independent Human Rights Commission.
"Such abuses are utterly unacceptable and are an affront to everything the international community stands for in Afghanistan"
UN special representative in Afghanistan
"We understand that, since 2002, steps have been taken in Bagram and other facilities to eradicate mistreatment and improve conditions of detention. We urge that such measures be made public without delay," Arnault said.
The statement added that complaints of arbitrary arrest, detention without charge and the treatment of detainees continue to be raised.
The UN Human Rights Commission last month failed to extend the mandate of Cherif Bassiouni, the independent expert on Human Rights in Afghanistan.
There were media reports of US pressure to dismiss Bassiouni after he issued a report alleging widespread abuse of prisoners in US military custody in Afghanistan.
Bassiouni's report said he had received credible reports of arbitrary detention, forced nudity, use of stress positions, sleep and food deprivation, sexual abuse, beatings and torture of prisoners in US detention.
At least eight prisoners have died in US custody in Afghanistan since 2001, most recently in September when detainee Sher Mohammad Khan died a day after his arrest in the southeastern province of Khost.
Hamid Karzai has expressed his
shock at the allegations
Military officials in Khost first told journalists in Kabul that he had died of a heart attack and later said he had been bitten by a snake.
In the case of the deaths in 2002 at Bagram Airbase, a US military spokesman maintained that both men had died of natural causes even after coroners had ruled the deaths homicides.
According to The New York Times, 27 soldiers faced probable criminal charges over the two Bagram deaths, but so far only seven have been charged with an offence.