A seized Iranian tanker held in Gibraltar is to be released, the local supreme court has ruled, despite a last-minute plea by the US authorities.
Gibraltar received formal written assurances from Iran that the ship would not discharge its cargo in Syria.
Grace 1, carrying Iranian oil, was stopped by Royal Marines on 4 July, triggering a standoff with Tehran.
Gibraltar’s chief justice, Anthony Dudley, said no US application was currently before the court.
A couple of weeks after the Iranian tanker was stopped, Iran seized a British-flagged tanker, the Stena Impero, in the Gulf and, despite official denials, there has been speculation of a swap if the Grace 1 is freed.
Relations between the US and Iran have deteriorated sharply since US President Donald Trump took office in 2017, with the two countries coming close to armed conflict in June.
How was the Iranian tanker seized?
It was stopped on 4 July after the government of Gibraltar suggested it was heading for Syria, in breach of EU sanctions against Syria.
Gibraltar’s authorities later received assurances from the captain of the ship and Iran that Grace 1 was not going to Syria.
About 30 marines were flown from the UK to Gibraltar to help police detain the tanker and its cargo, at the request of the Gibraltarian government.
The initial seizure of the tanker sparked a diplomatic crisis between the UK and Iran which escalated when the Stena Impero was seized on 19 July.
Last week, the UK announced it would join a US-led taskforce to protect merchant ships travelling through the key shipping route in the Strait of Hormuz.
Almost a fifth of the world’s oil passes through the narrow strait, which lies off the south coast of Iran.
Why are US relations with Iran so strained?
Washington suspects Iran of continuing efforts to develop nuclear weapons, something Tehran has always denied, and also accuses it of seeking to destabilise the Middle East.
Last year, the US withdrew from a 2015 deal to limit Iran’s nuclear activities and re-imposed sanctions against the country.
The UK and other European countries have said they remain committed to the deal.
Washington has also blamed Iran for a series of attacks on tankers in waters off Gulf Arab states over the summer, an accusation Tehran denies.
In June, Mr Trump was reportedly on the verge of bombing sites in Iran in response to the downing of one of its drones.