British nationals were advised not to travel to Iraq, apart from essential travel to its Kurdistan Region, while all but essential travel to Iran was warned against.
The guidance was being bolstered on Saturday after the United States announced it was sending nearly 3,000 extra troops to the region after Donald Trump authorised the killing of General Qassem Soleimani.
Thousands of mourners chanting "death to America" took to the streets of Baghdad, where the head of Iran's elite Quds force was targeted at the capital's international airport a day earlier.
The Foreign Office warned anyone in Iraq outside the Kurdistan Region should consider leaving by commercial means because the "uncertain" security situation "could deteriorate quickly".
Alerts regarding other Middle East nations were also being increased, with warnings that Britons should "remain vigilant" in Afghanistan, Israel, Lebanon and the Occupied Palestinian Territories.
Foreign Secretary Dominic Raab said the updated advice was issued due to "heightened tensions in the region" and would be kept under review.
"The first job of any Government is to keep British people safe," he added.
The US President said he ordered a strike to prevent a conflict, but Tehran has vowed harsh retaliation - raising fears of an all-out war.
An American official denied the nation was behind a second deadly air strike on two vehicles being reported north of Baghdad.
President Trump continued with his rhetoric despite widespread calls for calm, saying that Gen Soleimani's "reign of terror is over" and describing him as having a "sick passion" for killing.
Former foreign secretary Jeremy Hunt stressed the peril being faced after recent "extreme" actions by both the US and Iran, which have simmered since Mr Trump tore up a nuclear deal between the nations
"Well it's an incredibly dangerous game of chicken that's going on at the moment, because both sides have calculated that the other side cannot afford, and doesn't want, to go to war," he told BBC Radio 4's Today programme.
Mr Hunt said the tensions created a "very difficult situation" for the UK as an ally of the States, adding Britain "cannot afford to be neutral".
"But this is a very, very risky situation, and I think the job that we have to do as one of the US's closest allies is to use our influence to argue for more consistent US policy," he said.
There has been criticism of the US for not giving advanced notice of the attack to the UK, which has hundreds of troops deployed in Iraq.
Mr Hunt said the failure to notify was "regrettable" because allies should ensure "there are no surprises in the relationship".
Boris Johnson has been on holiday on the private Caribbean island of Mustique. He has not commented on the general's killing and Number 10 has not said when he will return.
Jeremy Corbyn wrote to the Prime Minister calling for an urgent meeting of the Privy Council, the group that advises monarchs.
The outgoing Labour leader wanted to know if the "assassination" had heightened the terror risk to the UK and whether the Government had been informed of the decision to strike.
He had earlier called on ministers to stand up to the US's "belligerent actions and rhetoric" and "urge restraint" from both aggressors.