A New Zealand court on Tuesday stopped a murder suspect from being extradited to China, saying it could not send him to a country where torture was "widespread" and "systemic".
The Court of Appeal quashed a ministerial decision to extradite Kyung Kim to China, saying to do so when there was a risk he would be tortured breached New Zealand's international obligations.
The 99-page judgement, which included a damning assessment of Beijing's justice system, comes amid huge protests by Hong Kong residents against a proposed law to allow extraditions to mainland China.
Kim's lawyer Tony Ellis said the decision was a precedent-setting human rights victory.
"It is a judgement that has profound human rights importance which will resonate throughout the Common Law world, it is not just important in New Zealand," he said in a statement.
Kim, a South Korean national who has lived in New Zealand for 30 years, is accused of murdering 20-year-old Chinese woman Pei Yun Chen while he was visiting Shanghai in 2009.
Kim was arrested in New Zealand in 2011 and Beijing asked for his extradition after giving assurances that he would not face the death penalty if convicted.
After a lengthy legal process that included two ministerial reviews, New Zealand in 2015 decided to extradite him -- the first time it had agreed to a suspect being sent to face trial in a Chinese court.
But Tuesday's ruling halted that process and ordered a third ministerial review, while raising questions about the Chinese legal system.
While the three-judge appeal panel conceded "a cultural shift away from torture in the PRC (People's Republic of China) is under way", it gave little weight to Chinese assurances Kim would receive a fair trial.
"Torture remains widespread and confessions obtained through torture are regularly admitted in evidence," the judgement said. "It logically follows, we consider, that there are inadequate systems in the PRC to prevent torture."
Other issues identified by the judges included political influence on the criminal justice system and the harassment of defence lawyers.
Beijing defended its human rights record in the wake of the ruling.
"In order to ensure justice to victims, we hope that New Zealand can handle the case fairly and extradite the suspect to China as soon as possible," foreign ministry spokesman Geng Shuang said during a regular press briefing in Beijing.
"China attaches great importance to the protection and promotion of human rights. The Chinese judicial system effectively protects the legitimate rights and interests of criminal suspects."
Kim spent five years in jail after his arrest and is currently on bail in Auckland.
His case will now go back to Justice Minister Andrew Little for review, although Kim's lawyer Ellis argued there was little chance of extradition given the "profound and important" questions posed by the Court of Appeal judgement.