Iran protests 'going nowhere', says Mahmoud Ahmadinejad
Mr Ahmadinejad told state television that "enemies" were trying to "tarnish the Iranian nation's brilliance".
Two people were killed and several wounded in clashes between protesters and security forces in central Tehran, officials said.
US President Barack Obama sharply criticised the authorities' response.
"I find it ironic that you've got the Iranian regime pretending to celebrate what happened in Egypt, when in fact they have acted in direct contrast to what happened in Egypt by gunning down and beating people who were trying to express themselves peacefully," he told reporters on Tuesday.
Mr Obama said the US could not dictate what went on inside Iran, but hoped people would have the "courage to be able to express their yearning for greater freedom and a more representative government".
'Ill-wishers'
Not long afterwards, Iran's president dismissed the protests in Tehran and other major cities, saying they had wanted to undermine a rally held last Friday to mark the 32nd anniversary of the Islamic Revolution.
"It is clear the Iranian nation has enemies because it is a nation that wants to shine, conquer peaks and change [its international] relations," he said.
He added: "Of course, there is a lot of hostility against the government. But they knew that they would get nowhere."
Mr Ahmadinejad said the organisers of the protests wanted "just wanted to tarnish the Iranian nation's brilliance".
"It is a shining sun. They threw some dust towards the sun... but the dust will return to their eyes."
On Monday, thousands gathered at Tehran's Azadi Square in solidarity with the uprisings in Tunisia in Egypt - their first major show of dissent since December 2009, when eight people were killed. Many chanted "Death to dictators".
The BBC's Mohsen Asgari, who was at the rally, says it was not long before riot police fired tear gas, while men on motorbikes charged the crowd with batons; Kazinform cites BBC News.
See www.bbc.co.uk for full version