It is a spartan life of dormitory beds, communal eating and prayer, but the Jangalak treatment centre in Kabul offers a rare glimmer of hope for heroin addicts caught in Afghanistan’s spiralling drug problem.

About 250 male addicts at a time undergo a 45-day course at the government centre, with 70 percent of all patients successfully staying off heroin after they leave.

Earlier this year, the U.N. drug and crime agency chief Yury Fedotov described the rapid rise of drug addiction in Afghanistan as a “national tragedy” in a country that is the world’s largest producer of opium, the raw form of heroin.

Efforts to cut opium production have failed completely in the 13 years since US-led forces arrived in Afghanistan, with Taliban insurgents often benefiting from the lucrative trade.

The latest U.N. survey has found that opium poppy cultivation rocketed to record levels last year with a 36 percent increase compared to 2012.

Addiction levels have also risen sharply — from almost nothing under the 1996-2001 Taliban regime, to more than one million heroin addicts today, according to UN figures.

Patients at Jangalak often arrive filthy, unkempt and mentally distressed.

They are washed, shaved and issued with new clothes before their treatment begins.

Doctors supervise medication as the addicts detoxify. The daily routine includes psychological support, regular exercise, games and prayer sessions.

Staff say the bonds that develop between recovering addicts are crucial to their chances of rebuilding their lives.