Dozens of Iraqi Shia militiamen and their supporters have broken into the US Embassy compound in Baghdad, smashing a main door and setting fire to a reception area in protest over deadly US air strikes targeting the Iran-backed militia.

US guards in the compound fired tear gas and palls of smoke rose over the grounds.

An Associated Press reporter at the scene saw flames rising from inside the compound and at least three US soldiers on the roof of the main embassy building.

There was a fire at the reception area near the compound’s car park but it was unclear what had caused it. A man on a loudspeaker urged the mob not to enter the compound, saying: “The message was delivered.”

Donald Trump blamed Iran for the embassy breach and called on Iraq to protect the diplomatic mission.

The US president tweeted: “Iran killed an American contractor, wounding many. We strongly responded, and always will. Now Iran is orchestrating an attack on the U.S. Embassy in Iraq. They will be held fully responsible.

“In addition, we expect Iraq to use its forces to protect the Embassy, and so notified!”

Iraq US Airstrikes
Protesters smash a window inside the compound (Khalid Mohammed/AP)

In Washington, the State Department said all US personnel at the embassy were safe, and there were no plans to evacuate the site. Defence secretary Mark Esper said the Pentagon was sending extras forces to support personnel at the embassy.

There were no reports of casualties, but the unprecedented breach was one of the worst attacks on the embassy in recent memory. It followed US air strikes on Sunday that killed 25 fighters of the Iran-backed militia in Iraq, the Kataeb Hezbollah.

The US military said the air strikes were in retaliation for last week’s killing of an American contractor in a rocket attack on an Iraqi military base that it blamed on the militia.

The developments represent a major downturn in Iraq-US relations that could further undermine American influence in the region and weaken Washington’s hand in its campaign against Iran.

Iraq has long struggled to balance its ties with the US and Iran, both allies of the Iraqi government, but the government’s angry reaction to the US air strikes and its apparent decision not to prevent the protesters from reaching the embassy signalled a sharp deterioration of relations.

Iraq US Airstrikes
Protesters damage property inside the compound (Khalid Mohammed/AP)

Iraqi security forces made no effort to stop the protesters as they marched to the heavily fortified Green Zone after a funeral held for those killed in the US strikes, letting them pass through a security checkpoint leading to the area.

The mob of marchers, many of them in militia uniforms, shouted “Down, Down USA!” and “Death to America” and “Death to Israel” outside the compound, hurling water and stones over its walls. The mob set fire to three trailers used by security guards along the wall.

Others then smashed the gates used by cars to enter and dozens pushed into the compound. The protesters stopped in a corridor after about 5 metres and were only about 200 metres away from the main building.

Half a dozen US soldiers were seen on the roof of the main building, their guns pointed at the protesters, and smoke from the tear gas rose in the area.

The protesters raised yellow militia flags and taunted the embassy’s security staff who remained behind the windows in the gates’ reception area. They hung a poster on the wall declaring, “America is an aggressor” and sprayed graffiti on the wall and windows.

Iraq US Airstrikes
The compound is inside the fortified Green Zone (Khalid Mohammed/AP)

An Iraqi employee at the embassy told the AP that the embassy’s security team had evacuated some local staff from a rear gate while others left by helicopter as the rest remained inside “safe” areas within the embassy.

Some commanders of militia factions loyal to Iran joined the protesters, including Qais al-Khizali, the head of one of the most powerful Iranian-backed Shia militias in Iraq, who is on a US terror list, and Hadi al-Amiri, the head of the Badr Organisation.

At least three protesters appeared to have difficulties breathing from tear gas. No one was immediately reported hurt in the rampage, and security staff had withdrawn to inside the embassy earlier, soon after protesters gathered outside.

The US air strikes — the largest targeting an Iraqi state-sanctioned militia in recent years — and the subsequent calls by the militia for retaliation, represent a new escalation in the proxy war between the US and Iran playing out in the Middle East.

US Secretary of State Mike Pompeo said Sunday’s strikes sent the message that Washington will not tolerate actions by Iran that jeopardise American lives.