Radical cleric Abu Qatada has unexpectedly volunteered to leave Britain if fresh guarantees that he will receive a fair trial are enshrined in law.
After fighting deportation for nearly a decade, Qatada has said he will return to the Middle East when a treaty between the UK and Jordan is ratified by both countries.
The agreement, unveiled by the Home Secretary last month, aims to allay fears that evidence extracted through torture will be used against the terror suspect at a retrial.
Meanwhile, Qatada, also known as Omar Othman, must wait to learn if he can be released from jail after his bail application at an immigration tribunal was adjourned to May 20.
The Government has been trying to deport Qatada to Jordan, where he was convicted of terror charges in his absence in 1999, for around eight years. In a bid to address concerns raised by immigration judges about the use of torture in Jordan, Theresa May unveiled a new agreement had been drawn up with the country.
At the Special Immigration Appeals Commission (Siac), Qatada's lawyer Edward Fitzgerald QC said: "If and when the Jordanian parliament ratifies the treaty, Mr Othman will voluntarily return to Jordan."
Mr Fitzgerald said Qatada's vow to return removed any risk that he would abscond if released on bail. He added: "There's never been a time in the last 12 years that Mr Othman and his family could safely return to Jordan. For a long period of time, he has made it clear that he wishes to leave lawfully."
Robin Tam QC, appearing for the Home Secretary, said the treaty would be laid before the Jordanian parliament in the next few weeks, while the UK side of the process should be completed by late June. Mr Justice Irwin asked Mr Tam to provide evidence of the process in the UK and Jordan in bringing the treaty into force. He added: "Not merely when it has been ratified but when it's in force."
Qatada was locked up in Belmarsh prison in March for breaching bail conditions which prevent him from turning mobile phones on in his house. The latest hearing had originally been called to determine whether he should be allowed to return to his taxpayer-funded home in London.
Shadow home secretary Yvette Cooper said: "This could be very good news if it means Abu Qatada returns to Jordan as soon as possible - as we all agree he should stand fair trial there so justice can be done. Abu Qatada should have made this decision a long time ago as this legal process has dragged on far too long. We will watch the next steps closely until he departs, but I hope this saga can now be brought to an end."