Tensions have spiked between Iran and Britain since last Friday when Iranian commandos seized a British-flagged tanker in the world's most important waterway for oil shipments. That came two weeks after British forces captured an Iranian oil tanker near Gibraltar, accused of violating sanctions on Syria.
HMS Montrose, a British frigate now in the area, carried out the first mission under the new policy on Wednesday evening.
"The Royal Navy has been tasked to accompany British-flagged ships through the Strait of Hormuz, either individually or in groups, should sufficient notice be given of their passage," a government spokesman said.
"Freedom of navigation is crucial for the global trading system and world economy, and we will do all we can to defend it," he added in a statement.
The British government had previously advised British-flagged vessels to avoid the Strait of Hormuz where possible and to notify the navy if they must cross it, but had said it would not be able to escort every ship.
Britain has been seeking to put together a European-led maritime protection mission to ensure safe shipping through the Strait of Hormuz after Iran's seizure of the tanker in what London said was an act of "state piracy".
The change of policy was not the result of a change made by new Prime Minister Boris Johnson, as the government had been working on the plan for a few days, according to a official, who asked not to be named.
The UK Chamber of Shipping trade association, which previously called for more protection of merchant vessels in the area, welcomed the change.
"This move will provide some much needed safety and reassurance to our shipping community in this uncertain time," said the chief executive, Bob Sanguinetti. "However, we will continue to push for a de-escalation of tensions in the region."
On any given day, about 15 to 30 large British-flagged ships travel in the Gulf, with up to three passing through the Strait of Hormuz between Iran and Oman, where a pair of two-mile-wide shipping lanes provide the only routes in and out of the Gulf.
About a fifth of the world's oil passes through the strait, and shipping companies are already deploying more unarmed security guards as an extra safeguard.
The cost of insuring a ship sailing through the region has risen tenfold as risks have risen, which has also prompted some ship owners to avoid the area entirely.
The United States, Britain and other nations will be meeting in Florida on Thursday to discuss how to protect shipping in the Gulf from Iran.
Washington, which has by far the strongest Western naval contingent in the Gulf, has been calling for its allies to join it in an operation to guard shipping there. But European countries, which disagree with a U.S. decision to impose sanctions on Iran, have been reluctant to sign up to a U.S.-led mission for fear of adding to tension in the region.
France, Italy and Denmark support Britain's idea of an EU-led flotilla in the Gulf, three EU diplomats said on Tuesday. Germany has said it is too early to discuss how Berlin might take part.
Iran says it is the guarantor of security in the strait. It will not allow any disturbance in shipping there, state news agency quoted Deputy Foreign Minister Abbas Araqchi as saying on Tuesday.