The authorities in Thailand agreed to let her return under the terms of an agreement with Britain that allows for the transfer of prisoners on compassionate grounds.
Gregory, 31, a former teacher, from Sowerby Bridge, West Yorkshire, is expected in England at the end of next week, when she will be taken initially to Holloway Prison, north London, to be assessed.
She is likely to request a transfer to a jail in the North in order to be nearer to family and friends.
Gregory, who will be accompanied by three male British prisoners, was given a 25-year sentence for attempting to export heroin. That was reduced by three years under an amnesty to mark the Thai king's golden jubilee. Under British law, she will be eligible for parole in six years.
Gregory was arrested at Bangkok airport with a companion, Robert Lock, as they were about to board a flight to Japan in February 1993. She was found in possession of three ounces of heroin and pleaded guilty, but claimed that Lock had paid her to smuggle the drugs out of Thailand. He has since been acquitted.
In Klong Prem jail in Bangkok, she has endured filthy and overcrowded conditions, poor diet and infestations of head lice.
Jackie Cox, a friend who has campaigned for her release, said yesterday: "We are absolutely delighted that we have at last reached the time when Sandra is coming home. She still has a long way to go before she is free, but a recent letter from her shows how much coming back to England means to her."Reuse content