Australian David Lambourne has been granted bail after the High Court judge was placed in immigration detention following a failed deportation attempt by the Kiribati government.
Justice Lambourne was served a deportation notice on Thursday morning and taken to the airport in Kiribati's capital Tarawa to be placed on a flight to Fiji.
The government said he had breached the conditions of his visitor's visa and posed a security risk to the Pacific nation.
Despite his lawyers securing a halt to the deportation from the Court of Appeal, authorities tried to force him onto a Fiji Airlines plane.
It led to a lengthy stand-off between authorities and a Fiji Airlines pilot who refused to fly Justice Lambourne against his will.
At a court of appeal hearing on Friday, the judge ruled the Attorney-General must take "all steps necessary to ensure that the respondent is not deported from Kiribati".
It added that attempts by police and immigration officers to force Justice Lambourne onto the plane were in breach of the court order.
"Such behaviour is unacceptable and risks putting the Attorney-General and the persons directly concerned in contempt of court. It must cease," the judgement said.
Justice Lambourne had suspected that the government would make another attempt to deport him on Sunday, when a Solomon Airlines flight is due to depart from Tarawa.
However, the court extended its order to "apply to any steps to deport the respondent under either of the deportation orders made yesterday or otherwise".
Prior to the hearing, the government lashed out at the court for what it said was interference.
"The Government of Kiribati is concerned by the overreach of the Court of Appeal in issuing an injunction against the deportation," the government said in a statement.
"It is disheartening to see neocolonial forces weaponising the laws that have been enacted to protect a Kiribati person to pursue their own interest and suppress the will of the people."
More than a visa breach
Justice Lambourne has been a resident of the Pacific nation for 27 years and is married to Tessie Lambourne, the leader of its opposition party.
He was suspended from his job by the government in May over alleged misconduct.
The government set up an independent tribunal, saying it had received complaints and allegations from the public against Justice Lambourne.
The allegations included "his inability to perform functions of his office and his misbehaviour", a government statement said.
The government did not specify what the complaints or allegations were.
Justice Lambourne returned to Kiribati on August 1 after being stranded in Australia since February 2020, when he returned to attend a conference.
The Kiribati government had made several attempts to prevent him from returning and resuming his position as a high court judge in the capital.
Last year, Justice Lambourne won a legal case against the government when it tried to refuse him entry back into Kiribati.
Then in June this year when he was due to appeal against his suspension, the government suspended Chief Justice William Hastings, who was due to hear the case.
The suspensions have left Kiribati without a functioning High Court.
Justice Lambourne returned to Kiribati on a visitor's visa, which the government has accused him of breaching, saying he has been working in the country since his arrival.
"Mr Lambourne has been insistently presenting himself and demanding to use his former office at the Kiribati Judiciary Office and disregarding the direction to vacate the premises," the government said.
Justice Lambourne dismissed the claims as "absolute rubbish".
The deportation order also stated that Justice Lambourne was a threat or risk to security.
The judge's ruling on Friday said deportation on those grounds was "unlawful", ordering that Justice Lambourne be immediately released from hotel detention.
A further hearing has been scheduled to take place on August 19.
A political target
Justice Lambourne said he believed he was being targeted because the government was trying to force his wife out of politics, calling it an "assault on the constitution".
"Given the very tenuous nature of the allegations that have been raised against me, this is just a very determined attempt by the government to try and force my wife out of politics," he told ABC's RN Breakfast.
"They clearly see her as a significant threat to them [and] the only way they can get to her is by getting me."
The country's constitutional system is on the brink of collapse with the suspensions of the senior judges, which Justice Lambourne says has led to a backlog of more than 2,000 cases.
"People are not getting access to justice and it's incredibly sad," he said.
He said he feared there might not be an end to the situation anytime soon.
"Clearly the government has decided that they want a compliance judiciary so they are trying to force the chief justice and I out," he said.
"It's hard to see how this plays out from here. The government is seemingly implacable and I can't see them backing down on this."
The Australian Department of Foreign Affairs and Trade said it was aware of Justice Lambourne's situation and was providing consular assistance.
Attorney-General Mark Dreyfus said he would make inquiries about the matter.