Tehran repeatedly denied the cases were related
The British-flagged oil tanker Stena Impero headed into port in Dubai on Saturday after being held off the Iranian port of Bandar Abbas for more than two months, according to authorities and a tracking website.
The ship's seizure was widely seen as a tit-for-tat move after authorities in the British overseas territory of Gibraltar detained an Iranian tanker on suspicion it was shipping oil to Syria in breach of EU sanctions.
Tehran repeatedly denied the cases were related.
The vessel sailed from Iran and into the international waters of the Gulf on Friday morning, according to local authorities.
"Despite the vessel's clearance, its legal case is still open in Iran's courts," Hormozgan province's maritime organisation said on its website.
The tanker's captain and crew have "given a written, official statement that they have no claims", it added.
British-flagged tanker heads into Dubai port after Iran release https://t.co/smxJNGYstH— The Daily Star Lebanon (@DailyStarLeb) September 28, 2019
The vessel arrived off the coast of Dubai shortly after 2000 GMT, and halted in the busy waterway overnight according to MarineTraffic.com, a ship tracking website.
It began heading to its anchorage in the emirate on Saturday morning, according to the website which said it was "underway using engine."
The CEO of Stena Bulk, the Swedish company that owns the vessel, said the ship's sailing was "obviously a relief" and that the priority now was those on board.
"When we reach Dubai we will firstly take care of the crew and then try and get the ship in operational order again," he told AFP on Friday.
The tanker's crew are "safe and in high spirits" and arrangements have been made for them to return to their families upon arrival in Dubai, Hannel said earlier.
"The crew will have a period of time to be with their families following 10 weeks of detainment on the vessel. Full support will be offered to the crew and families in the coming weeks to assist with their recovery," he added.
The company did not release the names of the crew members.
Iran's Revolutionary Guards seized the vessel in the Strait of Hormuz on July 19 after surrounding it with attack boats and rappelling onto its deck.
It was impounded off the port of Bandar Abbas for allegedly failing to respond to distress calls and turning off its transponder after hitting a fishing boat.
Seven of its 23 crew members were released on September 4.
British Foreign Secretary Domini Raab said the tanker was "unlawfully seized by Iran" as part of its attempts to "disrupt freedom of navigation."
Tensions have risen in the Gulf since May last year when President Donald Trump unilaterally abandoned a 2015 nuclear deal between major powers and Iran and began reimposing crippling sanctions in a campaign of "maximum pressure."
They flared again this May when Iran began reducing its own commitments under the deal and the US deployed military assets to the region.
Since then, ships have been attacked, drones downed and oil tankers seized.
In June, Trump called off air strikes against Iran at the last minute after the Islamic republic's forces shot down a US drone.
This month, twin attacks on Saudi oil infrastructure, which knocked out half the kingdom's production, drew accusations of blame not only from Washington, but also from its European allies.
Tehran has denied any involvement in the attacks which were claimed by Iran-backed rebels fighting a Saudi-led coalition in Yemen.
The US has since formed a coalition with its allies Australia, Bahrain, Britain, Saudi Arabia and the United Arab Emirates to escort commercial shipping in the Gulf.
Tehran has warned that the planned US-led International Maritime Security Construct will cause more, not less instability and has proposed a rival security plan of its own.
Speaking at the UN General Assembly in New York, President Hassan Rouhani this week announced a plan called "Hormuz Peace Endeavour" or "HOPE."
He gave no details but called on all of Iran's Gulf neighbours to join, saying: "Security cannot be provided with American weapons and intervention."
Foreign Minister Mohammad Javad Zarif tweeted Thursday that the plan calls for "dialogue, confidence-building, freedom of navigation, energy security, non-aggression, non-intervention."