A lesbian asylum seeker kicked out of the UK because she was caught in bed with a man must be brought back because she was unlawfully detained and deported, the High Court has ruled.

The 26-year-old, known only as PN, came to the country in 2010 aged 17, and stayed beyond her visa because she was fearful her uncle would kill her if she returned to Uganda.

She was arrested after her visa expired and was sent to the controversial Yarl's Wood detention centre.

In her asylum application PN claimed she faced persecution and possible execution if she returned to Uganda, as reported by The Times.

Home Office officials said when they raided PN's flat they found her in bed with a man

Her claim was rejected in 2013, and she was subsequently deported.

Home Office officials told the High Court when they raided her flat for visa violations they found her in bed with a man.

Investigators added the woman had not provided any evidence of a same-sex relationship in the UK or Uganda.

In a judgement, published by Mr Justice Lewis last week, he ruled the woman was denied the chance to show she had been in a lesbian relationship in Uganda, as reported by The Times.

He ruled the fast track appeals system - first introduced by Tony Blair's government in 2005 - did not give PN sufficient time to get evidence to support her claim.

Mr Justice Lewis quashed the decision and ordered the Home Secretary to 'use his best endeavours to facilitate the return of PN to the UK.'

PN is entitled to claim financial damages from from the government because she was unlawfully detained and deported.

Homosexuality is illegal in Uganda and the LGBT community can often face violence and discrimination.

Movement for Justice, a human rights group helping to support the woman told The Guardian the Home Office would likely appeal the decision.

A Home Office spokesman was not able to confirm when PN would be returning to the UK, or the likely amount of damages.