A supertanker suspected of carrying crude oil to Syria in violation of EU sanctions has been detained in Gibraltar, the British territory's Chief Minister Fabian Picardo has said.

Authorities did not say where the oil came from but specialised shipping trade publication Lloyd's List said the Panamanian-flagged tanker was thought to be transporting crude from Iran.

If confirmed, this would come at a sensitive time as the European Union mulls how to respond to Iran announcing it will breach the maximum uranium enrichment level it agreed in a landmark 2015 nuclear deal.

The 330-metre Grace 1 vessel was halted in the early hours of this morning by police and customs agencies in Gibraltar, which is on Spain's southern tip.

They were aided by a detachment of British Royal Marines.

The ship was detained 4km south of Gibraltar in what it considers British waters, although Spain, which lays claim to the territory, says they are Spanish.

It was boarded when it slowed down in a designated area used by shipping agencies to ferry goods to vessels.

"We have reason to believe that the 'Grace 1' was carrying its shipment of crude oil to the Banyas Refinery in Syria," Mr Picardo said in a statement.

"That refinery is the property of an entity that is subject to European Union sanctions against Syria."

"We have detained the vessel and its cargo," Mr Picardo said.

European Union sanctions against war-torn Syria have been in force since late 2011.

The 28-member bloc has imposed sanctions on 277 Syrian officials including government ministers over their role in the "violent repression" of civilians.

It has frozen the assets of some 72 entities and introduced an embargo on Syrian oil, investment restrictions and a freeze on Syrian central bank assets within the European Union.

Mr Picardo said he had "written this morning to the Presidents of the European Commission and Council, setting out the details of the sanctions which we have enforced".

In a statement, Britain's foreign office said "we welcome this firm action by the Gibraltarian authorities, acting to enforce the EU Syria Sanctions regime".

According to Lloyds List, which analysed vessel-tracking data, the 1997-built ship is the first tanker laden with Iranian oil to head for Europe since late 2018.

It reported that the ship loaded oil off Iran in April and sailed around the Cape of Good Hope in South Africa.

The tanker detention comes just days after Iran announced it would exceed the uranium enrichment limit set up as part of the 2015 deal to avoid it building up to the level required for a nuclear warhead.

Iran did this in response to the US abandoning the nuclear deal last year and hitting Iran's crucial oil exports and financial transactions with biting sanctions.