Shamima Begum - one of three east London schoolgirls who travelled to Syria to join the so-called Islamic State group (IS) - should be allowed to return to the UK to challenge the deprivation of her British citizenship, senior judges have ruled.

Ms Begum, now 20, travelled to Syria in February 2015 and lived under IS rule for more than three years before she was found, nine months pregnant, in a Syrian refugee camp in February last year.

Then-home secretary Sajid Javid revoked her British citizenship on national security grounds later that month.

Ms Begum took legal action against the Home Office, claiming the decision was unlawful because it rendered her stateless and exposed her to a real risk of death or inhuman and degrading treatment.

In February, the Special Immigration Appeals Commission (SIAC) - a specialist tribunal which hears challenges to decisions to remove someone's British citizenship on national security grounds - ruled the decision was lawful as Ms Begum was "a citizen of Bangladesh by descent" at the time of the decision.

The tribunal also found that she "cannot play any meaningful part in her appeal and that, to that extent, the appeal will not be fair and effective", but ruled that "it does not follow that her appeal succeeds".

Ms Begum's challenge to the Home Office's decision to refuse to allow her to enter the UK to effectively pursue her appeal was also rejected.

On Thursday, the Court of Appeal ruled that "the only way in which she can have a fair and effective appeal is to be permitted to come into the United Kingdom to pursue her appeal".

The Home Office branded the ruling "very disappointing" and said it would appeal, but Ms Begum's lawyers welcomed the news.

Lord Justice Flaux - sitting with Lady Justice King and Lord Justice Singh - said: "Fairness and justice must, on the facts of this case, outweigh the national security concerns, so that the leave to enter appeals should be allowed."

The judge found that "the national security concerns about her could be addressed and managed if she returns to the United Kingdom".

In its ruling, the court said: "If the Security Service and the Director of Public Prosecutions consider that the evidence and public interest tests for a prosecution for terrorist offences are met, she could be arrested and charged upon her arrival in the United Kingdom and remanded in custody pending trial."

Lord Justice Flaux also said: "With due respect to SIAC, it is unthinkable that, having concluded that Ms Begum could not take any meaningful part in her appeal so that it could not be fair and effective, she should have to continue with her appeal nonetheless."

He added: "It is difficult to conceive of any case where a court or tribunal has said we cannot hold a fair trial, but we are going to go on anyway."

Ms Begum's solicitor, Daniel Furner, from Birnberg Peirce, said she had "never had a fair opportunity to give her side of the story", adding that she is "not afraid of facing British justice, she welcomes it. But the stripping of her citizenship without a chance to clear her name is not justice - it is the opposite."

Lawyer Katie Lines, from human rights organisation Liberty which intervened in Ms Begum's appeal, said: "The right to a fair trial is not something the Government can take away on a whim.

"It is a fundamental part of our justice system and equal access to justice must apply to everyone."

Ms Begum was one of three schoolgirls from Bethnal Green Academy who left their homes and families to join IS, shortly after Sharmeena Begum - who is no relation - travelled to Syria in December 2014.

Kadiza Sultana and Amira Abase, then 16 and 15 respectively, and Ms Begum boarded a flight from Gatwick Airport to Istanbul, Turkey, on February 17 2015, before making their way to Raqqa in Syria.

Ms Begum claims she married Dutch convert Yago Riedijk 10 days after arriving in IS territory, with all three of her school friends also reportedly marrying foreign IS fighters.

She told The Times last February that she left Raqqa in January 2017 with her husband but her children, a one-year-old girl and a three-month-old boy, had both since died.

Her third child died shortly after he was born.

A Home Office spokeswoman said: "This is a very disappointing decision by the court.

"We will now apply for permission to appeal this judgment, and to stay its effects pending any onward appeal."