The Department of Health in Northern Ireland has issued an emergency licence to allow a 12-year-old boy to be treated with medicinal cannabis.
Billy Caldwell, who has a rare form of epilepsy, was granted a short-term licence by the Home Office to allow him access to cannabis oil.
His mother Charlotte says the medication helps to control his seizures.
The Caldwell family have been in London where Billy has been receiving treatment.
However the family said on Wednesday they were uncertain whether Billy would be able to continue receiving the medication when they returned home to Castlederg, Co Tyrone.
On Thursday, Northern Ireland's Department of Health announced it had issued an emergency licence to allow Billy access to his medication.
"The Department of Health yesterday received an emergency licence application from Belfast Trust clinicians regarding medicinal cannabis use for Billy Caldwell," a department spokeswoman said.
"An emergency licence has today been issued by the department, replicating the licence issued last month by the Home Office for treatment at Chelsea and Westminster Hospital in London.
"We have also been in discussions with the Home Office to finalise arrangements for the immediate transportation of Billy's medicine from London to the Belfast Trust."
Billy and Ms Caldwell are expected to fly into Belfast City Airport on Thursday evening.
Uncertainty over the medication in Northern Ireland earlier this week had placed a question mark over his return.
On Wednesday, the family claimed the Home Office decision needed to be ratified by the Department of Health in Northern Ireland before they could book flights home.
On Thursday morning, the family said they had booked flights but remained concerned over when Billy's next dose would be released.
The Department of Health said on Wednesday it was "actively working for a timely resolution to this matter".
Speaking earlier this week, Ms Caldwell said her son was longing to return home.
"Billy has been amazingly resilient throughout. He's autistic, and everything that has been going on - no regularity, no familiar surroundings - are beginning to take their toll on him," she said.
"He needs his toys, his garden, the things he's used to. I need to see him happy and well."
West Tyrone MP Orfhlaith Begley has welcomed the Department of Health's decision.
She said: "I have been in regular contact with Billy's mother Charlotte and the health authorities on both sides of the Irish sea urging them to end the delay in transferring Billy's medicinal cannabis licence to the North.
"We are still seeking clarity on where Billy will receive his treatment within the North.
"I, therefore, welcome the announcement that this licence will be administered in the North so that Billy can come home and continue his recovery.
"I will be there to meet Charlotte and Billy today at City airport to welcome them home."