STOCKHOLM -- Sweden's top prosecutor on Friday dropped an investigation into a rape claim against WikiLeaks founder Julian Assange after almost seven years, saying that's because there's no possibility of arresting him "in the foreseeable future."

The announcement by prosecutor Marianne Ny means the outspoken WikiLeaks leader no longer faces sex crime allegations in Sweden, although British police said was still wanted for jumping bail in Britain in 2012.

It does not clear Assange's name, however, and some experts say it puts him into an even more precarious legal situation if the U.S. has -- as some suspect -- a sealed indictment for his arrest.

Speaking from the balcony of Ecuador's London embassy, where he took refuge in 2012 to avoid extradition to Sweden, Assange said his seven-year legal ordeal -- which he called unjust detention -- "is not something that I can forgive."

He says his battle is not over, and "the proper war is just commencing." Assange, 45, believes the United States wants him extradited and arrested in connection with WikiLeaks' publication of classified U.S. documents.

He nonetheless called Sweden's decision to drop the rape investigation "an important victory for me and for the U.N. human rights system."

Assange has been holed up at Ecuador's embassy in London to avoid extradition to answer questions about sex-crime allegations from two women. The arrangement was necessary, he had said, to keep Swedish authorities from turning him over to the United States for his role at the helm of WikiLeaks, which has enraged governments around the world by publishing tens of thousands of leaked classified U.S. documents.

Assange said Friday his legal team would contact U.K. officials to seek a way forward in resolving his status. British police say they still intend to arrest him, if he leaves the Ecuadorean Embassy.

But London's Metropolitan Police added that Assange is now wanted for a "much less serious offence" than the original sex crimes claims, so police "will provide a level of resourcing which is proportionate to that offence."

British police kept up a round-the-clock guard outside the embassy until December 2015, when the operation was scaled back partly because of the costs, which had exceeded 11 million pounds (over $17.5 million at the time).

Assange also said he would be "happy" to discuss the case with the U.S. Department of Justice despite U.S. Attorney General Jeff Sessions saying that Assange's arrest was a priority.

"We've already begun to step up our efforts and whenever a case can be made, we will seek to put some people in jail," Sessions said last month.

U.S. President Donald Trump said last month he would support any decision by the Justice Department to charge Assange, who contends the United States should recognize his First Amendment rights as a journalist.

It's not known if U.S. officials have asked British police to arrest Assange because of a possible sealed U.S. indictment against him. A U.S. Department of Justice spokesman on Friday declined to comment on the case.

WikiLeaks tweeted after the Swedish announcement: "UK refuses to confirm or deny whether it has already received a US extradition warrant for Julian Assange. Focus now moves to UK."

British officials said they do not comment on individual extradition cases. British Prime Minister Theresa May said Friday that "any decision that is taken about U.K. action in relation to him (Assange) would be an operational matter for the police."

Ecuador's foreign minister, Guillaume Long, tweeted Friday that Britain "must now grant safe passage" to Assange. The South American country has granted him asylum.

At a press conference Friday in Stockholm, Ny, chief of the Swedish Prosecution Authority, said she "has decided to discontinue the investigation" and call back the European arrest warrant for Assange.

The allegations surfaced after two women accused Assange of sexual misconduct during a visit to Stockholm in 2010.

There were initially two separate allegations being investigated, but one was dropped in 2015 because the statute of limitations ran out. The rape allegation, the more serious claim, remained under investigation. Prosecutors were trying to determine, among other things, if Assange had sex with the woman while she was asleep and without using a condom.

Assange has said that all the sex was consensual.

Ny told reporters that prosecutors had been unable to make a full assessment of the case and were not making a finding on whether Assange was guilty or innocent of the allegations. She said the WikiLeaks founder had "tried to dodge all attempts at arrest" by British and Swedish authorities.

She said the case could be reopened if Assange returns to Sweden before the statute of limitations expires in 2020.

A lawyer for the woman who alleged she was raped by Assange said "it's a scandal that a suspected rapist can avoid the judicial system and thus avoid a trial in court."

Elisabeth Massi Fritz says her client is shocked by the Swedish decision but added that "she can't change her view that Assange has exposed her to a rape."

Per E. Samuelson, Assange's lawyer in Sweden, told The Associated Press that it was a "day of victory" for the WikiLeaks founder. He said Assange had convinced Swedish prosecutors during a November meeting last year that he was not guilty of any sex offences.

"The truth is, he gave a very good explanation: this was consensual sex between two adults and nothing else. And he's a free man," Samuelson said.

Assange and WikiLeaks have repeatedly infuriated U.S. officials with the widespread release of sensitive secret documents related to military operations in Afghanistan and Iraq and diplomatic relations around the world. WikiLeaks also had a provocative role in the 2016 U.S. presidential campaign when it published emails written by Hillary Clinton's campaign officials.

Army Pvt. Chelsea Manning served seven years in prison for giving classified material to WikiLeaks. She was freed Wednesday, having had her sentence commuted by former President Barack Obama before he left office.

Katz reported from London. Jill Lawless in London and Jan M. Olsen in Copenhagen, Denmark, contributed to this story

The Latest on Swedish prosecutor ending investigation of Wikileaks founder Julian Assange (all times local):

4:30 p.m.

Ecuador's Foreign Minister Guillaume Long celebrated the decision but expressed outrage over the lengthy delays by the Swedish prosecutors in resolving the case.

He said recent comments by U.S. Attorney General Jeff Sessions and U.S. President Donald Trump in favour of arresting the Australian reaffirm Ecuador's belief that the rape charges against him were politically motivated and that Assange still faces a serious risk of prosecution.

At a press conference in Quito, Long called on Britain allow Assange safe passage so he could take up his asylum in Ecuador. Long added: "This has gone on long enough. No more delays."

------

1:15 p.m.

Julian Assange's Swedish lawyer Per E. Samuelson says it is a "day of victory" for the WikiLeaks founder after Sweden's top prosecutor dropped an investigation into a rape claim against him.

Samuelson tells The Associated Press that "this was consensual sex between two adults and nothing else," adding Assange was now "a free man."

Samuelson says he spoke by telephone with Assange, who told him: "Yes, Per, it feels much better today. Finally we got there."

Samuelson said Sweden's judicial system "spoiled and wasted five, six years of his life ... but he is happy today."

------

12:45 p.m.

A lawyer for the woman who alleges she was raped by Julian Assange says "it is a scandal that a suspected rapist can avoid the judicial system and thus avoid a trial in court." Elisabeth Massi Fritz says her client is shocked but adds that "she can't change her view that Assange has exposed her to a rape."

------

12:05 p.m.

Julian Assange's lawyer is asking French president Emmanuel Macron to intervene in support of the WikiLeaks founder. Juan Branco told The Associated Press in Paris that he wants Macron to help Assange leave the Ecuadorean Embassy in London.

Branco says: "We need a political intervention to make this situation end. He is the only political prisoner in Western Europe."

------

11:45 a.m.

Sweden's top prosecutor says "costs were not a reason for putting down the investigation" of WikiLeaks founder Julian Assange.

Marianne Ny told a news conference: "When we investigate serious crimes, we do not consider the costs."

In a written statement, officials said: "According to Swedish legislation, a criminal investigation is to be conducted as quickly as possible. At the point when a prosecutor has exhausted the possibilities to continue the investigation, the prosecutor is obliged to discontinue the investigation.

"At this point, all possibilities to conduct the investigation are exhausted."

------

11:25 a.m.

Sweden's top prosecutor says the investigation of alleged sexual offences could reopened if Julian Assange returns to Sweden before the statute of limitations lapses in 2020.

The prosecutor, Marianne Ny, told a news conference in Stockholm that she could make no judgment on Assange's guilt or innocence. She says: "We don't make any statement of guilty or not."

------

11:20 a.m.

Sweden's top prosecutor, Marianne Ny, says she has withdrawn a European arrest warrant for WikiLeaks founder Julian Assange after concluding that it won't be possible to bring him to Sweden.

Ny told a news conference in Stockholm: "He has tried to dodge all attempts to avoid Swedish and British legal authorities. My assessment is the transfer cannot be carried out in a foreseeable future."

Ny says she has withdrawn a European arrest warrant. However, British police say Assange still faces arrest for jumping bail if he leaves the Ecuadorean embassy in London.

------

10:45 a.m.

Despite Sweden's decision to drop a rape investigation, British police say that Julian Assange still faces arrest if he leaves Ecuador's London embassy.

The Metropolitan Police force says that there is a British warrant for Assange's arrest after he jumped bail in 2012, and it "is obliged to execute that warrant should he leave the embassy."

But it adds that Assange is now wanted for a "much less serious offence" than the original sex crimes claims, and police "will provide a level of resourcing which is proportionate to that offence."

Police kept up round-the-clock guard outside the embassy until last year, when the operation was scaled back.

------

10:30 a.m.

WikiLeaks says the ball is now in Britain's court after Sweden's decision to drop its rape investigation of Julian Assange.

Assange is wanted by British police for extradition to Sweden. But he also believes the United States wants to extradite him to face charges related to WikiLeaks' publication of classified American documents.

After the Swedish announcement. WikiLeaks tweeted: "UK refuses to confirm or deny whether it has already received a US extradition warrant for Julian Assange. Focus now moves to UK."

British police said before the announcement that Assange is still wanted in Britain for jumping bail. It is not clear if that may change now that the investigation has been dropped.

------

10:20 a.m.

Sweden's top prosecutor says she is dropping an investigation into a rape claim against WikiLeaks founder Julian Assange after almost seven years.

The Swedish Prosecution Authority said in a statement Friday that Marianne Ny "has decided to discontinue the investigation."

Assange took refuge in Ecuador's embassy in London in 2012 to escape extradition to Sweden to answer questions about sex-crime allegations from two women. He has been there ever since, fearing that if he is arrested he might ultimately be extradited to the United States.

Friday's announcement means Assange is no longer under any investigation in Sweden. British police said before the announcement that Assange is still wanted in Britain for jumping bail. It is not clear if that may change now that the investigation has been dropped.

AP Writer Gonzalo Solano contributed from Quito, Ecuador