Cryonics is a controversial technique as no one knows whether it's actually possible to bring people back from the dead.

The girl's mother supported her wish to be preserved, but her father was against the idea, which led to the case being heard at the High Court.

The judge ruled that the girl's mother should be allowed to decide what happened to her daughter's body. The ruling has been described as "historic".

The girl was reportedly "delighted" by the judge's decision (which has only just been made public) and called him a "hero".

Her body is now in the U.S. and is being preserved for an infinite amount of time at a cost of £37,000. It is frozen using liquid nitrogen at a temperature of less than -130C. There are currently no such facilities to enable the procedure in the UK.

Before she died, the girl wrote to the judge, Justice Peter Jackson, that she wanted to be frozen to potentially "live longer" if a cure for her disease is found in future, reported the BBC.

"I think being cryopreserved gives me a chance to be cured and woken up - even in hundreds of years' time," she wrote. "I don't want to be buried underground.

"I want to live and live longer and I think that in the future they may find a cure for my cancer and wake me up."