Wikileaks founder Julian Assange has said he will turn himself over to UK police on Friday if a UN panel rules he has not been unlawfully detained.
He took refuge in London's Ecuadorian embassy in 2012 to avoid extradition to Sweden over sexual assault claims.
In 2014 he complained to the UN that he was being "arbitrarily detained" as he could not leave without being arrested.
The Met Police said Mr Assange, who denies the claims against him, would be arrested if he left the embassy.
The UK Foreign Office said Mr Assange had voluntarily avoided lawful detention, saying it still has an obligation to extradite him.
It comes as the UN's Working Group on Arbitrary Detention is due to announce the findings of its investigation into Mr Assange's case on Friday.
The panel of legal experts took evidence from the UK and Sweden. It has made previous rulings on whether imprisonment or detention is lawful although it does not have any formal influence over the British and Swedish authorities.
Australian Mr Assange was originally arrested in London in 2010 under a European Arrest Warrant issued by Sweden. He was granted asylum by Ecuador and entered the country's embassy in Knightsbridge after the UK Supreme Court ruled the extradition against him could go ahead.
His Wikileaks organisation posted secret American government documents on the internet, and Mr Assange says he believes Washington will seek his transfer to the US if he is sent to Sweden.
In the statement published by Wikileaks on Twitter, Mr Assange said: "Should the UN announce tomorrow that I have lost my case against the United Kingdom and Sweden I shall exit the embassy at noon on Friday to accept arrest by British police as there is no meaningful prospect of further appeal.
"However, should I prevail and the state parties be found to have acted unlawfully, I expect the immediate return of my passport and the termination of further attempts to arrest me."
Caroline Hawley, BBC diplomatic correspondent, said Mr Assange claims his time inside the embassy does amount to detention "as he would be arrested if he came out".
Last year, Swedish prosecutors dropped two sex assault claims against Mr Assange. However, he still faces the more serious accusation of rape.
Our correspondent said Swedish prosecutors were now preparing to allow Ecuadorian officials to put questions to Mr Assange - who has previously indicated he would be willing to be questioned inside the embassy.
"As I understand it the latest is that Ecuadorian officials have said that their prosecutors, rather than Swedish prosecutors, would put questions to Julian Assange. Surprisingly to me, the Swedish prosecutor has accepted that," she said.
Questions were now being compiled and translated for Ecuadorian officials, our correspondent added.
Mr Assange's friend, journalist Vaughan Smith - who gave him refuge at his home in 2010 - said he now wanted to see "a resolution" to the case.
He said the Wikileaks founder viewed himself as "a political prisoner", saying he had gone into the embassy to maintain his liberty.
Mr Smith told BBC Radio 4's Today programme that he viewed Mr Assange as a "sort of a dissident".
Last October, Scotland Yard said it would no longer station officers outside the Ecuador embassy following an operation which it said had cost £12.6m. But it said "a number of overt and covert tactics to arrest him" would still be deployed.
Two months earlier, Swedish officials said they were optimistic about reaching an agreement with Ecuador which could pave the way for the questioning of Mr Assange in London.