Iran-backed militiamen withdrew from the U.S. Embassy compound in Baghdad on Wednesday after two days of clashes with American security forces, but U.S.-Iran tensions remain high and could spill over into further violence. The withdrawal followed calls from the government and senior militia leaders.

It ended a high-stakes two-day crisis and practical siege of the largest and one of the most heavily fortified U.S. diplomatic missions in the world. The attack prompted the Pentagon to send hundreds of additional troops to the Middle East.

In an orchestrated assault, hundreds of militiamen and their supporters broke into the embassy compound, destroying a reception area, smashing windows and spraying graffiti on walls to protest U.S. airstrikes against an Iran-backed militia over the weekend that killed 25 fighters. The U.S. blamed the militia for a rocket attack on an Iraqi military base in the northern city of Kirkuk last week that killed a U.S. contractor.

Get Breaking News Delivered to Your Inbox

Secretary of State Mike Pompeo called the assault "state-sponsored terror" in an exclusive interview with CBS News on New Year's Eve. "This is Iranian-backed terrorism that took place that threatened American interests," Pompeo told CBS News chief Washington correspondent Major Garrett. "We've taken a fundamentally different approach. We have starved them of resources. We've denied them access. We've put pressure on the Iranian leadership, and I think you see that."

Pompeo on Wednesday postponed a trip to Ukraine, the country at the heart of impeachment proceedings against President Trump, to "continue monitoring the ongoing situation in Iraq and ensure the safety and security of Americans in the Middle East," the State Department said in a statement.

The protesters set up a tent camp overnight and on Wednesday set fire to the reception area and hurled stones at U.S. Marines guarding the compound, who responded with tear gas. There were no injuries on either side and no American staff were evacuated from the compound.

The Popular Mobilization Forces, an umbrella group of state-allied militias — many backed by Iran — called on its supporters to withdraw in response to an appeal by the Iraqi government, saying "your message has been received." By late afternoon the tents had been taken down and the protesters relocated to the opposite side of the Tigris River, outside the so-called Green Zone housing government offices and foreign embassies.

U.S. Apache helicopters circled overhead. "After achieving the intended aim, we pulled out from this place triumphantly," said Fadhil al-Gezzi, a militia supporter. "We rubbed America's nose in the dirt."

Kataeb Hezbollah, the Iran-backed militia targeted by the U.S. airstrikes, initially refused to leave but later bowed to demands to disperse. The militia is separate from the Hezbollah militant group in Lebanon, though both are backed by Iran.

"We don't care about these planes that are flying over the heads of the picketers. Neither do we care about the news that America will bring Marines," said Mohammed Mohy, a spokesman for Kataeb Hezbollah. "On the contrary, this shows a psychological defeat and a big mental breakdown that the American administration is suffering from," he said, before withdrawing from the area.

A protester holds a placard with an illustration of President Trump burning outside the U.S. Embassy in Baghdad, Iraq, January 1, 2020, during a protest to condemn airstrikes against an Iran-backed militia. Reuters/Khalid al-Mousily

The violence came as Iran and its allies across the region have faced unprecedented mass protests in recent months and heavy U.S. sanctions have cratered Iran's economy. Iraq has been gripped by anti-government protests since October fueled by anger at widespread corruption and economic mismanagement, as well as Iran's heavy influence over the country's affairs.

Those protesters were not involved in the embassy attack. President Trump blamed Iran for the attack on the embassy and the Pentagon dispatched an infantry battalion of about 750 soldiers to the Middle East.

A U.S. official familiar with the decision told the Associated Press they would go to Kuwait. Iran denied involvement in the attack on the embassy.

Supreme Leader Ayatollah Ali Khamenei was quoted by media as saying that "if the Islamic Republic makes a decision to confront any country, it will do it directly." Iran later summoned the Swiss charge d'affaires, who represents American interests in Tehran, to protest what it said was war-mongering by U.S. officials.

Tensions have steadily risen since Mr. Trump withdrew the U.S. from Iran's 2015 nuclear deal with world powers and embarked on a campaign of maximum pressure through economic sanctions. Iran has responded by abandoning some of its commitments under the deal.

U.S. officials have blamed Iran for the sabotage of oil tankers in the Persian Gulf and a drone attack on Saudi oil facilities in September that caused a spike in world oil prices. But the Trump administration has not responded with direct military action, apparently fearing a wider conflict.

The U.S. has sent more than 14,000 additional troops to the Gulf region since May in response to concerns about Iranian aggression. At the time of the attack, the U.S. had about 5,200 troops in Iraq, mainly to train Iraqi forces and help them combat extremists with the Islamic State of Iraq and Syria group, or ISIS.

The U.S. and Iran have vied for influence over Iraq since the 2003 U.S.-led invasion that toppled Saddam Hussein. Iran has close ties to Iraq's Shiite majority and major political factions, and its influence has steadily grown since then.

Iran helped to mobilize tens of thousands of mostly Shiite militiamen to battle ISIS when it stormed across northern and western Iraq in 2014 as the armed forces collapsed. The U.S. and Iran both provided vital aid to Iraqi forces, who eventually declared victory over the extremists in December 2017.

The political influence of the Popular Mobilization Forces has risen in recent years, and their allies dominate the parliament and the government. That has made them the target of the anti-government protesters, who have attacked Iranian diplomatic missions and the local headquarters of parties affiliated with the militias across southern Iraq.

They have also set up a sprawling protest camp in central Baghdad, and for weeks have been trying to enter the Green Zone. Iraqi security forces have beaten them back with tear gas and live ammunition, killing hundreds.

The militiamen and their supporters, however, were able to quickly enter the Green Zone and mass in front of the embassy, with little if any resistance from authorities. Iraq's government vehemently condemned the airstrikes on the militia, saying it violated national sovereignty.

But Iran and its allies might have also seen the attack as a way of diverting attention from the anti-government protests. "Iran has been trying to provoke the U.S. into helping it solve its Iraq problem," the Crisis Group, an international think tank, said in a briefing on the crisis. "The Trump administration, by responding to the attacks in Kirkuk and elsewhere with airstrikes, has obliged."