Being afraid of extradition to the United States over his whistleblowing organization's exposure of classified documents, Assange has been living at Ecuador's embassy in London since summer 2012, being granted political asylum, thereby breaching his bail conditions.
Assange, 46, has hidden out in the embassy for the last five years, avoiding extradition to Sweden on rape charges, as well as a bail-violation rap in the UK.
If he were to leave Ecuador's embassy, Assange would face arrest by British police.
Assange himself first announced the ruling on Twitter.
Senior District Judge Emma Arbuthnot, the Chief Magistrate, said in a short judgment (PDF, five pages) that "it is for the accused to prove he has reasonable cause for his failure to surrender".
A prosecutor did however say that if Assange is ever passing through Sweden, he should still pop in.
Mr Assange came to worldwide prominence in 2010 when his website Wikileaks released tens of thousands of classified military and diplomatic documents.
He said the request would effectively reward him with "immunity from being dealt with" by "having managed to evade proceedings sufficiently long that they fall away for whatever reason".
They said Assange's medical problems included "a awful bad tooth, frozen shoulder and depression".
Mr Assange was interviewed in November 2016 at the Ecuadorian embassy and the interview was relayed to Swedish prosecutors.
This meant bail warrant was the only thing keeping Assange in the embassy. "Mr Assange failed to surrender to custody".
In December, Assange was granted Ecuadorean citizenship after applying for it months earlier. Some carried placards reading "Assange safe passage" and "Don't shoot the messenger".