The decision puts the Ecuadorian and British government at loggerheads. The Foreign Office has confirmed it will not allow him safe passage to the South American country and Metropolitan police will arrest the Australian activist as soon as he sets foot out the embassy in Knightsbridge.

Moments after the press conference, at which Ecuadorian journalists applauded the government minister, the Foreign Office put out a statement.

“We are disappointed that Ecuador has offered political asylum to Julian Assange," it said.

"Under our law, with Mr Assange having exhausted all options of appeal, the British authorities are under a binding obligation to extradite him to Sweden. We shall carry out that obligation. The Ecuadorian government's decision this afternoon does not change that."

Assange was reported as saying the decision was a "significant victory" but that "things will get more stressful now".

Speaking in the afternoon, foreign secretary William Hague said the asylum claims was an attempt to sidestep a legal process.

"The UK does not accept the principle of diplomatic asylum," he said.

"It is far from a universally accepted concept: the United Kingdom is not a party to any legal instruments which require us to recognise the grant of diplomatic asylum by a foreign embassy in this country.

"Moreover, it is well established that, even for those countries which do recognise diplomatic asylum, it should not be used for the purposes of escaping the regular processes of the courts. And in this case that is clearly what is happening."

The stalemate comes as Ecuador complains of a British "threat" to temporarily revoke the diplomatic immunity of its embassy, so that officers can take Assange into custody and extradite him to Sweden, where he is wanted for questioning over allegations of sexual assault.

Police and demonstrators gathered at the embassy as tensions rose over the international diplomatic incident. Three arrests were made this morning as police tried to move demonstrators to the other side of the street into a penned area.

In Ecuador demonstrators gathered outside the British embassy and stamped on the national flag while chanting anti-British slogans.

"Today we received from the United Kingdom an express threat, in writing, that they might storm our embassy in London if we don't hand over Julian Assange," Patino said in a dramatic press conference yesterday.

"Ecuador rejects in the most emphatic terms the explicit threat of the British official communication."

He added: "If the measure announced in the British official communication is enacted, it will be interpreted by Ecuador as an unacceptable, unfriendly and hostile act and as an attempt against our sovereignty. It would force us to respond.

"We are not a British colony."

The letter Patino received was being played down by the Foreign Office this morning, but it does mention the Diplomatic and Consular Premises Act 1987, which allows the government to revoke diplomatic status of an embassy on UK soil. Foreign Office spokespeople insisted the government was merely laying out all the options.

"We need to reiterate that we consider the continued use of the diplomatic premises in this way incompatible with the Vienna convention and unsustainable and we have made clear the serious implications that this has for our diplomatic relations," the letter reads.

The legislation provides for the revocation of a building's diplomatic status where the foreign country "ceases to use land for the purpose of its mission or exclusively for the purposes of a consular post".

It was passed after the Libyan embassy siege of April 1984 in which WPC Yvonne Fletcher was shot and killed - and a separate problem with squatters at the Cambodian embassy.

Experts have said the UK government's threat to remove the Ecuadorian embassy's diplomatic status, allowing the Metropolitan police to enter the building and seize Assange, could prove extremely controversial.

Legal analysts doubt whether the British threat will stand up when challenged by the Convention of Vienna, the international law which governs countries' diplomatic status.

It would require many months of legal wrangles before officers were able to enter the premises.

Lawyer Carl Gardner told the Today programme that Britain was in "uncharted territory", while Britain's former ambassador to Russia Tony Brenton suggested the Foreign Office had "overreached themselves for both tactical and legal reasons".

He added: "If the Russians had had the power to simply walk into the embassy and arrest someone... life would have been much more difficult."

Assange is wanted by Swedish authorities to face questions about sexual offences against two women during a trip to Stockholm in 2010.

The Wikileaks founder denies the allegations and claims the charges are the product of US government agencies, who are trying to have him sent to America for the release of diplomatic cables two years ago.