Iranian Foreign Minister Mohammad Javad Zarif said on Twitter on Friday that any military presence in the Gulf from outside the region would be a "source of insecurity" for Iran, and Tehran would act to safeguard its security.
Washington is lobbying international partners to join a maritime security coalition at a time of heightened tensions with Iran. Tehran earlier on Friday warned against any presence of its arch-foe Israel in the planned coalition.
"(The) Persian Gulf is a vital lifeline and thus nat'l security priority for Iran, which has long ensured maritime security," Zarif said in his tweet.
"Mindful of this reality, any extra-regional presence is by definition (a) source of insecurity ... Iran won't hesitate to safeguard its security," Zarif said.
Britain said on Monday it was joining the United States in the maritime security mission in the Gulf to protect vessels after Iran seized a British-flagged tanker.
Traffic in the Strait, through which about a fifth of the world's oil passes, has become the focus of a standoff between Iran and the United States after President Donald Trump quit a 2015 nuclear pact and reimposed sanctions on Tehran.
Iran says the responsibility of securing these waters lies with Tehran and other countries in the region.
The United Arab Emirates and Saudi Arabia, which support U.S. policy against Iran, have called on the international community to safeguard maritime trade and security of global oil supplies.