Convicted drug smuggler Michaella McCollum has been granted permission to transfer from Peru to a jail closer to home in Northern Ireland.
Her accomplice Melissa Reid from Scotland is waiting on the South American authorities agreeing to the terms of her move back to the UK. The pair were jailed last year for six years and eight months after admitting trying to smuggle cocaine worth £1.5 million from Peru to Spain.
A solicitor has described the conditions of their detention as horrendous.
The Irish government has been providing consular support to McCollum, an Irish citizen.
A letter from the Republic's department of foreign affairs said: "The Peruvian authorities have confirmed that they have accepted Michaella's prison transfer request and have passed this to the UK National Offenders' Management Service (Noms) which co-ordinates prisoner transfers to the UK.
"In Ms McCollum's case, Noms liaises with the Northern Ireland Prison Service and with the Peruvian Prison Service on all aspects of the transfer."
It could be months before she returns home as the logistics of the transfer will be complicated, the note to McCollum's solicitor stated.
Prisoners must be accompanied throughout their journey; airlines and airports must be advised, with security arrangements put in place at departure, transit and final stops. Her final destination is likely to be Ash House Women's Prison at Hydebank Wood in south Belfast.
A Northern Ireland Prison Service spokesman said: "We don't normally comment on individual cases. All transfer requests are however dealt with as expeditiously as possible."
McCollum, aged 21 and from Dungannon, Co Tyrone, and Reid, aged 20 and from Glasgow, were caught with the haul at Lima airport on August 6 last year.
They were working on the Spanish party island of Ibiza when they claimed Colombian drug lords who kidnapped them at gunpoint forced them to board a flight with 24lb of cocaine in food packets hidden inside their luggage.
McCollum and Reid faced the prospect of a maximum 15-year prison term but struck a behind-closed-doors plea bargain to secure a shorter sentence.
They had previously been held at Lima's Virgen de Fatima prison but were moved to the Ancon 2 prison, where horrific conditions reportedly mean McCollum is crammed into a cell with 30 other prisoners.
The situation at the mixed prison, which is two-and-a-half hours from Lima, has previously been criticised by the Irishwoman's lawyer as "appalling".
Kevin Winters said sanitation and toilet facilities are extremely poor and all females have to use a hole in the ground which has to be covered up because of the presence of vermin.
Reid's father, from Lenzie, near Glasgow, has said he has met Scotland's justice secretary Kenny MacAskill and is hopeful that his daughter will serve the rest of her sentence closer to home.
The Scottish Prison Service (SPS) said it has approved a repatriation application it received from Lima earlier this year.
Prison chiefs are now waiting for the Peruvian authorities to agree on the terms of the transfer before it can take place.
A SPS spokeswoman said: "We have provisionally given consent to the Peruvian authorities for the application."
Patrick Corrigan, Amnesty International's Northern Ireland director, said w ith massive overcrowding, poor access to medical care and endemic corruption throughout Peru's penal system, it is understandable that prisoners from the UK and Ireland want to return home to complete their sentences.
He added Peru's prisons are full to overflowing, with almost 50,000 prisoners for fewer than 30,000 prison places.
"The Virgen de Fatima and Ancon jails, where Melissa Reid and Michaella McCollum Connolly have been serving their jail terms, suffer from the same problems as the rest of Peru's prison system, which has a reputation for being deeply corrupt, with prisoners even forced to pay for food and clean water.
"Significant investment is required to bring the country's jails up to internationally accepted standards for prison conditions such as would be expected in the UK."