Britain's high court today granted bail to Julian Assange, the WikiLeaks founder who is wanted in Sweden for questioning over allegations of rape.

Mr Justice Duncan Ouseley agreed with a decision by City of Westminister magistrates court earlier in the week to release Assange on strict conditions: £200,000 cash deposit, with a further £40,000 guaranteed in two sureties of £20,000, and strict conditions on his movement.

Assange stood in a dark grey suit in the dock as Ouseley began hearing an appeal by British prosecutors acting on behalf of Sweden.

There was an early sign that the day would go in Assange's favour when Ouseley said: "The history of the way it [the case] has been dealt with by the Swedish prosecutors would give Mr Assange some basis that he might be acquitted following a trial."

Mark Stephens, one of Assange's lawyers, said he expected Assange to be released later today, or tomorrow in a worst case scenario.

"We are hopeful that he will be released from here [the court] but if the formalities are not completed before the bus goes back to Wandsworth, he will be released from Wandsworth later," Stephens said.

"We haven't addressed the question of American legal action or the potential for it. Our main focus is delight and joy, and delight and joy of Julian's family, that he is going to be released in the very foreseeable future. He will not be going back to that Victorian prison. He will not be going back to that cell once occupied by Oscar Wilde."

The Crown Prosecution Service suggested that Assange's wealthy supporters were offering surety for a cause, not because they could vouch for him.

The 39-year-old Australian arrived at the high court in a white prison van. Photographers swarmed around the vehicle in an attempt to get a picture. Amid intense media interest, a queue of journalists had formed as early as 6am.

Stephens said before the proceedings that the bail money had been raised from Assange's supporters and "appears to be in the banking system". .

Assange has been held in solitary confinement, released from his cell for only one hour a day, and his mail has been heavily censored, according to his supporters.

Assange is fighting attempts to extradite him to Sweden for questioning over allegations of sexual misconduct including rape made by two female WikiLeaks volunteers, which he denies.

"It's an ongoing investigation in Sweden and the prosecutor needs to interrogate him to make a decision on the matter," said Karin Rosander, a spokeswoman for the Swedish prosecution agency.

Bail conditions stipulate that Assange must stay at a country house in Suffolk owned by Vaughan Smith, the founder of the Frontline club in west London, report to police daily and wear an electronic tag.

Meanwhile, it emerged that the decision to seek a remand in custody for Assange was taken by the British authorities and not by prosecutors in Sweden.

It had been widely supposed that Sweden had taken the decision to oppose bail, with the Crown Prosecution Service acting merely as its representative. But the Swedish prosecutor's office told the Guardian it had "not got a view at all on bail" and that Britain had made the decision to oppose bail.

Karin Rosander, the director of communications for Sweden's prosecutor's office, said: "The decision was made by the British prosecutor. I got it confirmed by the CPS this morning that the decision to appeal the granting of bail was entirely a matter for the CPS. The Swedish prosecutors are not entitled to make decisions within Britain. It is entirely up to the British authorities to handle it."

As a result, she said, Sweden would not submit any new evidence or arguments to the high court hearing. "The Swedish authorities are not involved in these proceedings. We have not got a view at all on bail."

The CPS confirmed that decisions to oppose bail for Assange had been taken by its lawyers. "In all extradition cases, decisions on bail issues are always taken by the domestic prosecuting authority," it said. "It would not be practical for prosecutors in a foreign jurisdiction … to make such decisions."

Assange and his lawyers have expressed fears of a legal battle in the US, where prosecutors may be preparing to indict him for espionage over WikiLeaks' publication of the documents.

The New York Times reported that federal prosecutors were looking for evidence that Assange had conspired with a former US army intelligence analyst suspected of leaking classified documents.

Among the material prosecutors are studying is an online chat log in which Private Bradley Manning is said to claim that while he was downloading government files he was directly communicating with Assange using an encrypted internet conferencing service, according to the Times. Manning is also said to have claimed that Assange gave him access to a dedicated server for uploading some of them to WikiLeaks.