Iran rejected an allegation by U.S. Defense Secretary James Mattis that it was "the primary exporter of terrorism" and said on Saturday that the main source was U.S. ally Saudi Arabia.
"Some countries led by America are determined to ignore the main source of Takfiri-Wahhabi terrorism and extremism," foreign ministry spokesman Bahram Ghasemi was quoted by Iran's state news agency IRNA as saying.
He was referring to hardline Sunni Muslim groups and Saudi Arabia's official Wahhabi school of Islam.
Saudi Arabia denies backing terrorism and has cracked down on Islamist militants at home, jailing thousands, stopping hundreds from travelling to fight abroad and cutting militant finances.
Shia Muslim power Iran and Saudi Arabia, bastion of Sunni Islam and a close U.S. ally, are longstanding religious and political arch rivals and often accused each other of backing terrorism.
"Giving a wrong address when referring to the roots and the financial and intellectual resources of terrorism is a main reason for a lack of success by international anti-terror efforts," Ghasemi added.
Ghasemi was reacting to remarks by Mattis on Friday when he was asked about comments he made in 2012 that the three main threats the United States faced were "Iran, Iran, Iran".
"At the time when I spoke about Iran I was a commander of U.S. Central Command and that (Iran) was the primary exporter of terrorism, frankly, it was the primary state sponsor of terrorism and it continues that kind of behaviour today," Mattis told reporters.