LONDON — Britain on Monday joined an American-led mission to protect ships traveling through the Strait of Hormuz from Iranian threats, signaling a greater openness to working with the United States to shore up maritime security in the region and acknowledging that its efforts to create a European-led task force have proved difficult.
Tensions between Britain and Iran have been rising since Iran seized a tanker flying the British flag in July. That followed Britain’s decision to impound an Iranian tanker near Gibraltar on suspicion that it violated a European Union embargo on the sale of oil to Syria.
But Britain at the time resisted the idea of joining its maritime forces with the United States, and instead described plans for a European-led mission in the area.
Britain’s decision to join the American-led security effort came after Prime Minister Boris Johnson took office. Mr. Johnson has made strengthening ties with the United States a priority, in part because a free-trade agreement with Washington is a centerpiece of his plans for Brexit.
American officials have blamed Iran for apparent attacks on tankers in May and June, which came after new sanctions that aimed to cut off its ability to sell oil, a pillar of its economy. Iran has denied involvement.
Last month, the American military downed an Iranian drone in the Strait of Hormuz in what President Trump called an act of self-defense.
Since Mr. Trump abandoned a 2015 deal intended to prevent Iran from obtaining a nuclear weapon, Britain has occupied a pivotal place in a bloc of Euoprean states trying to save the accord and broker a resolution to the conflict between Tehran and Washington.
Britain’s decision on Monday to join the American-led effort was an acknowledgment that its efforts to create a European maritime security coalition had not yet been successful; no other European countries have committed warships to protect merchant shipping in the region.
Instead, Britain said it would commit the same two warships it had previously assigned to escort British-flagged ships through the strait to the American-led mission. Britain and the United States are the only two countries contributing to the effort.
Ben Wallace, the British defense secretary, said Britain was “determined to ensure shipping is protected from unlawful threats.”
But the British government said its broader policy of saving the 2015 nuclear deal had not changed. That deal has been under threat since the United States imposed crippling economic sanctions in May and Iran began taking steps to restart its nuclear program.
“Our approach to Iran hasn’t changed,” Dominic Raab, Britain’s foreign secretary, said. “We remain committed to working with Iran and our international partners to de-escalate the situation and maintain the nuclear deal.”
Shipping through the Strait of Hormuz has become fraught since Iran began building its military presence in the Gulf and threatened to block exports through the strait in response to the American sanctions.
Iran has suggested that it might release the British-flagged tanker it captured in exchange for the return of the Iranian ship seized by the British military off Gibraltar. But Britain has ruled out a swap.