Supporters of Shia militia storm into US Embassy compound in Baghdad

Dozens of angry Iraqi Shia militia supporters have broken into the US Embassy compound in Baghdad after smashing a main door and setting fire to a reception area, prompting tear gas and gunfire.

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 building inside the embassy. It was not clear what caused the fire at the reception area near the parking lot of the compound.

The attack followed US air strikes on Sunday that killed 25 fighters of the Iran-backed militia in Iraq, the Kataeb Hezbollah. The US military said that was in retaliation for last week's killing of an American contractor in a rocket attack on an Iraqi military base that it had blamed on the militia.

Dozens of protesters marched inside the compound after smashing the gate used by cars to enter the embassy. The protesters, many in militia uniform, stopped in a corridor after about five metres, and were only about 200 metres from the main building.

Iraq US Airstrikes
Iraqi Shia militia supporters at theembassy compound (Qassim Abdul-Zahra/AP)

Half a dozen US soldiers were seen on the roof of the main building, their guns were pointed at the protesters.

Smoke from the tear gas rose in the area, and at least three protesters appeared to have difficulties breathing.

The protesters hung a poster on the wall saying "America is an aggressor".

Shouting "Down, Down USA", the crowd had earlier raised yellow militia flags and taunted the embassy's security staff who remained behind the glass windowed reception area. They sprayed graffiti on the wall and windows in red in support of the Kataeb Hezbollah militia.

Iraq US Airstrikes
The compound is in the fortified Green Zone (Qassim Abdul-Zahra/AP)

No one was immediately reported hurt in the rampage and security staff had withdrawn inside the embassy earlier, soon after protesters gathered outside.

The US attack — the largest targeting an Iraqi state-sanctioned militia in recent years — and 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.

Tuesday's incident took place after mourners and supporters held funerals for the militia fighters killed in a Baghdad neighbourhood, after which they marched to the heavily fortified Green Zone and the sprawling US Embassy.

US secretary of state Mike Pompeo said Sunday's strikes sent the message that the US will not tolerate actions by Iran that jeopardise American lives.