The US has launched retaliatory air strikes against a pro-Iranian militia group in Iraq after a rocket attack killed two of its soldiers.
The strikes targeted five weapons storage facilities across the country, the US defence department said.
The Iraqi military says three soldiers, two policemen and a civilian were killed in the US counter-strikes.
It said the US had carried out "a blatant attack" on Iraqi military sites in Babil province and an airport under construction in Karbala province. It also said the headquarters of the Popular Mobilisation (PM) forces - an umbrella militia which is officially part of the Iraqi security forces - had been hit.
Earlier, a US commander said Kataib Hezbollah - one of the most powerful groups in the PM - was likely to have fired the rockets.
"The Iranian proxy group Kataib Hezbollah is the only group known to have previously conducted an indirect fire attack of this scale against US and coalition forces in Iraq," Central Command chief Gen Kenneth McKenzie told a Senate committee.
The defence department confirmed a series of "defensive precision strikes" had been carried out by manned aircraft against five Kataib Hezbollah facilities that stored weapons including rockets.
We have effectively destroyed these facilities and expect that they no longer contain the type of advanced Iranian-supplied weapons that were used in the KH attacks.— U.S. Central Command (@CENTCOM) March 13, 2020
– Gen Frank McKenzie, CDR CENTCOM pic.twitter.com/ag27fZnCoO
"These include facilities that housed weapons used to target US and coalition troops," it said. "[The strikes] were defensive, proportional, and in direct response to the threat posed by Iranian-backed Shia militia groups."
"The United States will not tolerate attacks against our people, our interests, or our allies," Defence Secretary Mark Esper added. "We will take any action necessary to protect our forces."
The US has accused Iran-backed militias of 13 similar attacks on Iraqi bases hosting coalition forces in the past year.
The killing of an American civilian in one such incident in December triggered a round of violence which ultimately led Mr Trump to order the assassination of top Iranian general Qasem Soleimani and Kataib Hezbollah commander Abu Mahdi al-Muhandis the following month.
By Nafiseh Kohnavard, BBC Persian, on a US military base in Irbil
Thursday night's attack was significant. US jets targeted Kataib Hezbollah and other Iran-backed militia groups in areas that even during the fight against the Islamic State (IS) group were considered a no-fly zone for coalition drones and planes.
It comes days before a 15 March deadline issued by pro-Iranian militia in Iraq for all US forces to leave the country and any Iraqis working with the US to stop doing so.
The strikes weren't only a retaliation against the rocket attacks on the Taji base, which killed three members of the US-led coalition - they were also aimed at reducing the groups' capabilities.
Although this was not a coalition-led operation, it increases the pressure on coalition forces combating IS here in Iraq. After the US killing of Soleimani, the Iraqi parliament voted to expel all foreign forces, especially the US, from the country.
The coalition remains here as a guest of the Iraqi government - but some Shia Muslim militia say US forces are occupiers and they will not stop attacking US bases until they leave Iraq completely.
What's the background?
Taji base, about 15km (nine miles) north of Baghdad, hosts foreign troops from the US-led coalition, whose mission is to train and advise Iraqi security forces.
It was struck by about 18 Katyusha rockets fired from the back of a lorry, according to the US military.
Iraqi journalist Ali Al Dulaimy, who filmed the attack from the nearby town of Baji, said he had heard screams of panic from American troops inside the camp, and had seen them rushing to put out fires.
عاااجل ❗❗— Ali Al Dulaimy (@Ali69760507) March 11, 2020
تم قصف الآن معسكر التاجي الذي يضم قوات الأمريكية عراقية من قبل المليشيات الآن 👇 pic.twitter.com/OR1wnOLsEv
Hours later, a UK-based monitoring group reported an air strike on PM militiamen in eastern Syria, which it said killed 26 people.
UK Prime Minister Boris Johnson described the rocket attack on Camp Taki as "deplorable" while the US defence secretary said President Donald Trump had authorised a response and warned that all options were on the table.
The UK Ministry of Defence identified the British soldier killed as Lance Corporal Brodie Gillon, a Combat Medical Technician who served as a Reserve with the Scottish and North Irish Yeomanry.
The two American personnel who died were active-duty troops with the US Army and Air Force, a US military official told the New York Times.
Why is Iraq being drawn into the US-Iran confrontation?
Tensions between the arch-foes intensified last year, after Iran-linked fighters targeted US military and civilian personnel with rocket attacks. There were also unclaimed air strikes in Iraq targeting militia facilities and Iranian officials.
In late December, a rocket attack on an Iraqi military base killed a US civilian contractor. The US blamed Kataib Hezbollah and carried out air strikes on its bases in Iraq and Syria that left at least 25 fighters dead.
The US embassy in Baghdad was then attacked by crowds of protesters, and President Trump warned Iran it would "pay a very big price".
On 3 January, Mr Trump authorised a drone strike near Baghdad airport that killed Qasem Soleimani - commander of the Islamic Revolution Guard Corps' Quds Force and architect of Iranian policy in the Middle East - and Abu Mahdi al-Muhandis.
Five days later, Iran launched ballistic missiles at Iraqi bases hosting US forces. The attack left more than 100 US troops with traumatic brain injuries.
Iran's Supreme Leader, Ayatollah Ali Khamenei, said the missile attack was "a slap in the face" for the US and vowed to end the American presence in the region.
There are about 5,000 US personnel and hundreds more from other countries in Iraq. They are deployed at the request of the government but the parliament passed a bill following Soleimani's killing demanding the invitation be rescinded.