An Afghan man is understood to have become the first atheist ever to secure asylum in Britain on religious grounds.

His case was accepted by the Home Office on the basis there was a risk he could face persecution in Afghanistan for having rejected Islam.

Although he was brought up a Muslim, since living in the UK he has gradually turned away from it and is now an atheist. The young man – who does not want to be identified for fear of being rejected by the Afghan community in Britain – fled to the UK from a conflict involving his family in Afghanistan.

Download the new Independent Premium app Sharing the full story, not just the headlines

He first claimed asylum in 2007 when he was just 16. The claim was rejected but he was granted discretionary leave to remain until 2013 under rules to protect unaccompanied children.

The case was taken up by Kent Law Clinic, a pro bono service provided by students and supervised by practising lawyers from the University of Kent’s Law School, alongside local solicitors and barristers. A submission to the Home Office argued that the man’s return to Afghanistan could result in a death sentence under Sharia law as an “apostate” – someone who has abandoned their religious faith – unless he remained silent about his atheist beliefs.

His fears of persecution became more acute after attending a friend’s wedding in Pakistan, according to evidence presented to the Home Office. The man says he as shocked by how people responded to him, with one telling him: “You cannot sit and eat with people who are not Muslim”. He said he believed the situation would be worse in Afghanistan.

Evidence presented to the Home Office also suggested that because daily life and culture in Afghanistan is permeated by Islam, living discreetly would be virtually impossible. The submission read: “The Applicant’s lack of religion causes him to live in fear of the prospect of being returned to a country where religion is both prevalent and dominant in society”.

Claire Splawn, a second year law student at the University of Kent, prepared the case. Ms Splawn said: “We argued that an atheist should be entitled to protection from persecution on the grounds of their belief in the same way as a religious person is protected.”

Sheona York, who supervised the case, said: “The decision represents an important recognition that a lack of religious belief is in itself a thoughtful and seriously-held philosophical position.”

A Home Office spokesman said: “We do not routinely comment on individual cases. The UK has a proud history of granting asylum to those who need it and we consider every application on a case by case basis.”