By Parisa Hafezi
ANKARA (Reuters) - Hundreds of thousands of Iranians rallied on Friday to swear allegiance to their clerical leaders and reject U.S. President Donald Trump's warning that he had put the Islamic Republic "on notice", state TV reported.
On the anniversary of Iran's 1979 Islamic Revolution that toppled the U.S.-backed Shah Mohammad Reza Pahlavi, marchers including hundreds of military personnel and policemen streamed towards Tehran's Azadi (Freedom) Square for the main event.
They carried "Death to America" banners and effigies of Trump while a military police band played traditional Iranian revolutionary songs.
State TV showed footage of people stepping on Trump's picture in a central Tehran street. Marchers carried the Iranian flag and banners saying: "Thanks Mr Trump for showing the real face of America."
"America and Trump cannot do a damn thing. We are ready to sacrifice our lives for our leader", a young man told state TV, in a reference to Supreme Leader Ayatollah Ali Khamenei.
Last week, Trump put Iran "on notice" after a Jan. 29 Iranian missile test and imposed fresh sanctions on individuals and entities. Iran said it will not halt its missile program.
Leading religious and political figures, including President Hassan Rouhani, had urged Iranians to join the rally on Friday to "show their unbreakable ties with the Supreme Leader and the Islamic Republic".
Tehran and Washington cut diplomatic ties shortly after the revolution, when hardline students stormed the U.S. embassy in Tehran and took 52 Americans hostage for 444 days.
Among Iranian officials attending the ceremony was Qasem Soleimani, who heads Iran's Quds Force and is in charge of foreign operations of the elite Revolutionary Guards Corps.
Iran said it had smashed an underground cell linked to Islamic State in recent days that it said wanted to "sabotage and carry out devilish acts" at the rallies.
"Some inexperienced figures in the region and America are threatening Iran ... They should know the language of threats has never worked with Iran," Rouhani told the crowd at Azadi Square. "We are not seeking tension but we are united before bullying and any threat."
The rallies bristled with anti-U.S. and anti-Israeli sentiment. Some protesters carried pictures of Trump, Israeli Prime Minister Benjamin Netanyahu and British Prime Minister Theresa May with the caption "Death to the Devil Triangle".
"This turnout of people is a strong response to false remarks by the new leaders of America," Rouhani told state TV, which said millions had turned out at rallies across Iran.
Many Iranians on social media such as Twitter and Facebook used the hashtag #LoveBeyondFlags to urge an end to burning of U.S. flags, a regular feature of these anniversary events.
They also thanked Americans for opposing Trump's executive order banning travelers from seven mainly Muslim countries - including Iran - from entry to the United States. The travel ban is being challenged in U.S. courts.
Some marchers in the crowds carried banners that read: "Thanks to American people for supporting Muslims".
Both U.S.-based social media sites are blocked by the government in Iran but many Iranians get around the restrictions to use them. Iranian officials, including Khamenei, have Twitter and Facebook accounts despite the ban.
Trump has criticized a nuclear deal reached between Iran, the United States and other major powers in 2015 aimed at curbing the country's nuclear work. Most of the sanctions imposed on Iran were lifted last year under the deal.
Rouhani defended the deal, which his hardline rivals oppose as a concession to pressure from Washington. He said it protected the Islamic Republic’s rights to nuclear power, ending Iran's political isolation and crippling economic sanctions.
(Writing by Parisa Hafezi; Editing by Tom Heneghan)