The Islamic Revolutionary Guard Corps swiftly took credit, and one Iranian politician tweeted his nation’s flag -- an apparent swipe at President Donald Trump who tweeted the American flag after the U.S. killing of Iranian Gen. Qassem Soleimani.
"We warn the Great Satan, the arrogant American regime that any new invasions and aggression will result in more painful and pounding responses," Iran's Islamic Revolutionary Guard Corps stated.
Later, Iran's Foreign Minister Javad Zarif tweeted, "Iran took & concluded proportionate measures in self-defense under Article 51 of UN Charter targeting base from which cowardly armed attack against our citizens & senior officials were launched."
"We do not seek escalation or war, but will defend ourselves against any aggression," he added.
Late Tuesday, President Donald Trump tweeted, "All is well! Missiles launched from Iran at two military bases located in Iraq. Assessment of casualties & damages taking place now. So far, so good! We have the most powerful and well equipped military anywhere in the world, by far! I will be making a statement tomorrow morning."
The recent developments were expected to spark global fear of a U.S. war in the Middle East. Iranian leaders had vowed revenge for the death of Soleimani, who the U.S. has blamed for the recent death of an American military contractor as well as being behind roadside bombs assessed to have killed 600 American troops in Iraq.
A Pentagon spokesman estimated that there were more than a dozen ballistic missiles launched from Iran beginning at about 5:30 p.m. EST. A defense official told ABC News that 10 of the missiles hit Al Asad, one struck Irbil in northern Iraq and four "failed in flight."
"It is clear that these missiles were launched from Iran and targeted at least two Iraqi military bases hosting U.S. military and coalition personnel at Al Asad and Irbil," wrote Pentagon spokesman Jonathan Hoffman.
A defense official said there was no information on possible casualties, but the U.S. is "still conducting battle damage assessments." But a senior administration official and a U.S. official told ABC News late Tuesday that there were no indications of American casualties so far.
About a quarter of the Iranian ballistic missiles that were fired "failed" -- implying that they were either intercepted by air defenses or missed their targets, the senior administration official said. One of the U.S. officials said there was no additional activity from Iran.
The president and congressional leadership were briefed immediately after the strikes. The defense official told reporters that Defense Secretary Mark Esper and Gen. Mark Milley, chairman of the Joint Chiefs of Staff, were in the Pentagon while the attack occurred and spoke by phone to the president, vice president and national security team. They then went to the White House to brief Trump in person.
"We are aware of the reports of attacks on U.S. facilities in Iraq," according to a statement from White House press secretary Stephanie Grisham. "The President has been briefed and is monitoring the situation closely and consulting with his national security team."
House Speaker Nancy Pelosi being handed a note in the middle of a leadership meeting. Rep. Debbie Dingell, who was present during the meeting, said Pelosi asked the other lawmakers to pray.
Pelosi then spoke with Vice President Mike Pence by phone, according to the two offices.
"We must ensure the safety of our servicemembers, including ending needless provocations from the Administration and demanding that Iran cease its violence. America & world cannot afford war," Pelosi tweeted.
An all-Senate classified briefing on Iran was still expected to be held Wednesday afternoon.
An Iranian news outlet, ISNA, dubbed the attack "Operation Martyr Soleimani" and said the ground-to-ground missiles were aimed at "terrorist and invasive U.S. forces."
"The body of General Soleimani is being buried now. After taking revenge of his blood, now his body is being buried," according to a statement from Iran to members of the foreign press.
The Federal Aviation Administration says U.S. airlines are banned from flying over Iran, Iraq, the Persian Gulf and the Gulf of Oman for now. The notice says the ban is due to "heightened military activities and increased political tensions in the Middle East, which present an inadvertent risk to U.S. civil aviation operations due to the potential for miscalculation or misidentification."
U.S. government officials have said that Soleimani has long been regarded as an enemy of American security interests, but that past administrations calculated that killing him was not worth the risk, including launching a potential war with Iran.
When asked why his calculation was different, resulting in a U.S. drone strike targeting Soleimani as he traveled inside Iraq, Trump and his top aides insisted that he was planning an attack on U.S. service members and diplomats. A small group of senior lawmakers, including Pelosi, were briefed on that intelligence on Tuesday.
"He was planning a very big attack and a very bad attack, for us, and for other people," Trump told reporters on Tuesday afternoon prior to the missile attack on U.S. sites in Iraq.
In a Pentagon briefing Tuesday afternoon, also before the Iranian strikes were launched, Defense Secretary Mark Esper told reporters that the U.S. was ready to defend itself.
"I would like to say we are not looking to start a war with Iran. But we are prepared to finish one," Esper said.
He said the U.S. wants Iran to "sit down with us to begin a discussion about a better way ahead."
Trump visited Al Asad Airbase in December 2018, his first visit to U.S. troops in a combat zone since becoming president.
"We're no longer the suckers, folks," Trump told the service members during the visit, according to the Associated Press. "We're respected again as a nation."
ABC News' Anne Flaherty, Stephanie Ebbs, Matthew McGarry, Ben Gittleson, Kyra Phillips, Somayeh Malekian, Kirit Radia and Mariam Khan contributed to this report.