Khamenei ordered security forces to bring to justice those responsible for one of the worst assaults ever against the Revolutionary Guards, the most powerful and heavily armed military force in the country, which answers to him.
The allegation will likely ratchet up tensions with Iran's rival Saudi Arabia and its Gulf allies, who along with the United States have been working to isolate the Islamic Republic.
"This crime is a continuation of the plots of the regional states that are puppets of the United States, and their goal is to create insecurity in our dear country," Khamenei said in a statement published on his website.
He did not name the regional states he believed were to blame. Israel is also a key US ally opposed to Tehran.
The assault, which wounded more than 60 people, targeted a stand where Iranian officials had gathered in the city of Ahvaz to watch an annual event marking the start of the Islamic Republic's 1980-88 war with Iraq, state television said.
The bloodshed struck a significant blow to security in the oil producer, which has been relatively stable compared with neighbouring Arab countries that have grappled with upheaval since the 2011 uprisings across the Middle East.
An Iranian ethnic Arab opposition movement called the Ahvaz National Resistance, which seeks a separate state in oil-rich Khuzestan province, claimed responsibility for the attack.
Islamic State militants also claimed responsibility. Neither claim provided evidence. All four attackers were killed.
Women and children died in the assault, state news IRNA agency reported.
The assailants had hidden weapons in an area near the parade route several days in advance, said Brigadier General Abolfazl Shekarchi, a senior spokesman for Iran's armed forces.
"All four terrorists were quickly neutralized by security forces," Shekarchi told state television. "A four-year-old girl and a wheelchair-bound war veteran were among the dead."
Attacks on the military are rare in Iran.
The Islamic Revolutionary Guards Corp (IRGC) has been the sword and shield of Shi'ite clerical rule in Iran since its 1979 Islamic Revolution.
The Guards have a big say in Iran's regional interests and a vast stake worth billions of dollars in Iran's economy.
A video distributed to Iranian media showed soldiers crawling to escape gunfire. One picked up a gun and scrambled to his feet as women and children fled for their lives.
A video on state television's website showed confused soldiers. Standing in front of the stand, one asked: "Where did they come from?" Another responded: "From behind us."
Ahvaz is in the centre of Khuzestan province, where there have been sporadic protests by minority Arabs. Activists said the Revolutionary Guards had arrested several people in Ahvaz after the attack.
The gunmen were trained by two Gulf Arab states and had ties to the United States and Israel, according to Shekarchi.
“They are not connected to ISIS, but to the US and to the Israeli Mossad,” he said.
There was no immediate Gulf Arab comment on his remarks.
Mainly Shi'ite Iran and mostly Sunni Saudi Arabia support opposite sides in wars in Syria and Yemen and rival political parties in Iraq and Lebanon.
The attack occurred a day before Iranian President Hassan Rouhani heads to New York to address the annual UN General Assembly next week.
"Rouhani will use the terrorist attack to justify Iran's presence in the Middle East ...The attack will strengthen the IRGC's position inside Iran and in the region, a Tehran-based political analyst Hamid Farahvashian said.
Iran will face pressure to respond to the high-profile attack, which has hurt the security establishment's prestige.
"The attacks are doubtlessly meant to tarnish the prestige of the IRGC, but I believe the terrorist incidents will strengthen the IRGC's standing and even mobilise some public support," said Ali Alfoneh, senior fellow at the Gulf Arab States Institute in Washington.
Hardliners like the IRGC have gained standing at the expense of pragmatists in Iran's multi-tiered leadership since President Donald Trump decided in May to pull the United States out of the 2015 international nuclear deal with Tehran and reimpose sanctions on the Islamic Republic.
Kurdish militants killed 10 Revolutionary Guards in an attack on an IRGC post on the Iraqi border in July.
Last year, in the first deadly assault claimed by Islamic State in Tehran, 18 people were killed at the parliament and mausoleum of Ayatollah Ruhollah Khomeini, the founder of the Islamic Republic.