A gay teenager who sought sanctuary in Britain when his boyfriend was executed by the Iranian authorities now faces the same fate after losing his legal battle for asylum.

Mehdi Kazemi, 19, came to London to study English in 2004 but later discovered that his boyfriend had been arrested by the Iranian police, charged with sodomy and hanged.

In a telephone conversation with his father in Tehran, Mr Kazemi was told that before the execution in April 2006, his boyfriend had been questioned about sexual relations he had with other men and under interrogation had named Mr Kazemi as his partner.

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

Fearing for his own life if he returned to Iran, Mr Kazemi claimed asylum in Britain. But late in 2007 his case was refused. Terror-stricken at the prospect of deportation the young Iranian made a desperate attempt to evade deportation and fled Britain for Holland where he is now being detained amid a growing outcry from campaigners.

He appeared before a Dutch court yesterday to plead with the authorities not to return him to Britain where he is almost certain to be sent back to Iran.

In a letter to the British Government, Mr Kazemi has told the Home Secretary, Jacqui Smith: "I wish to inform the Secretary of State that I did not come to the UK to claim asylum. I came here to study and return to my country. But in the past few months my situation back home has changed. The Iranian authorities have found out that I am a homosexual and they are looking for me." He added: "I cannot stop my attraction towards men. This is something that I will have to live with the rest of my life. I was born with the feeling and cannot change this fact but it is unfortunate that I cannot express my feeling in Iran. If I return to Iran I will be arrested and executed like my former boyfriend."

Mr Kazemi's future will now be decided by a Dutch appeal court, which will rule whether to grant him permission to apply for asylum in Holland, which offers special protection to gay Iranians, or whether he will be deported to Britain. His case has attracted support from leading gay rights groups across Europe who are campaigning to allow him to live in Britain.

Omar Kuddus, from Gay Asylum UK, said that Britain must do more to protect homosexual asylum-seekers such as Mr Kazemi: "The challenge and legality under question and debate in the Dutch court is if he can or should be deported back to the UK under the Dublin Treaty which compels EU states to send asylum-seekers to the first European country they claim asylum."

Peter Tatchell, of the gay rights campaign group Outrage, described the Government's policy as "outrageous and shameful". He said: "If Mehdi is sent back to Iran he will be at risk of execution because of his homosexuality. This is a flagrant violation of Britain's obligations under the refugee convention.

"It is just the latest example of the Government putting the aims of cutting asylum numbers before the merits of individual cases. The whole world knows that Iran hangs young, gay men and uses a particularly barbaric method of slow strangulation. In a bid to fulfil its target to cut asylum numbers the Government is prepared to send this young man to his possible death. It is a heartless, cruel mercenary anti-refugee policy."

Daily coronavirus briefing No hype, just the advice and analysis you need Enter your email address Continue Continue Please enter an email address Email address is invalid Fill out this field Email address is invalid Email already exists. Log in to update your newsletter preferences Register with your social account or click here to log in I would like to receive morning headlines Monday - Friday plus breaking news alerts by email Update newsletter preferences

Emma Ginn, of the National Coalition of Anti-Deportation Campaigns, met Mr Kazemi at the Tinsley House removal centre, near Gatwick airport, while he was being detained by the Home Office. She recalls: "Mehdi was very anxious when I visited him in Tinsley. The Home Office planned to deport him two days later to Iran where he risked being executed like his boyfriend had been. I'm not surprised he fled the UK."

According to Iranian human rights campaigners, more than 4,000 gay men and lesbians have been executed since the Ayatollahs seized power in 1979. The last reported case of the death penalty imposed against a gay man was that of Makwan Moloudzadeh, 21, who was executed in December after being convicted for sodomy, or lavat, a capital offence under Iranian law.

Last year, the Foreign Office released correspondence sent between embassies throughout the EU dating back to May 2005. They refer specifically to the case of two gay youths, Mahmoud Asqari, under 18 at the time of his execution, and Ayad Marhouni, who were hanged in public.

The Home Office's own guidance issued to immigration officers concedes that Iran executes homosexual men but, unaccountably, rejects the claim that there is a systematic repression of gay men and lesbians.

The Government has a policy of not commenting on individual cases but a Home Office spokeswoman said: "The UK Government is committed to providing protection for those individuals found to be genuinely in need, in accordance with our commitments under international law. If an application is refused, there is a right of appeal to an independent judge, and we only return those who have been found by the asylum decision-making process and the independent courts not to need international protection.

"We examine with great care each individual case before removal and we will not remove anyone who we believe is at risk on their return. However, in order to maintain the integrity of our asylum system and prevent unfounded applications it is important that we are able to enforce returns of those who do not need protection." She added: "The Dublin Regulation states that an asylum applicant should make an application for protection in the first 'safe' country they reach having left their own country. If they do not do so, the Regulation permits the return of asylum applicants to the third country where the substantive asylum claim was made."

Click here to have your say