In apparent defiance of Iran's supreme leader, a powerful cleric declared his country in crisis after a disputed poll, and tens of thousands of protesters used Friday prayers to stage the biggest show of dissent for weeks.

Clashes erupted later in central Tehran between police and followers of opposition leader Mirhossein Mousavi, who still contests the election result that showed hardline President Mahmoud Ahmedinejad had been re-elected by a wide margin.

Police fired tear gas and beat supporters of Mousavi in Keshavarz Boulevard, a witness said, adding that protesters were carrying hundreds of green banners -- Mousavi's campaign color -- and chanting 'Ahmadinejad, resign, resign'.

Former President Akbar Hashemi Rafsanjani, a moderate who backed Mousavi's election campaign, said many Iranians had doubts about the official result of the June 12 vote.

I hope with this sermon we can pass through this period of hardships that can be called a crisis, said the influential cleric, leading prayers for the first time since the poll.

Live state radio broadcasts of Friday prayers at Tehran University, with a dual religious and political sermon delivered by a top cleric, have been a staple of revolutionary Iran.

No senior establishment figure has previously described the post-election turmoil as a crisis for the Islamic Republic.

Rafsanjani's remarks posed a clear challenge to Supreme Leader Ayatollah Ali Khamenei, who has upheld the election result and accused foreign powers of fomenting the unrest.

In the streets outside Tehran University, police used tear gas and batons to disperse Mousavi supporters who had flocked to the prayers. At least 15 people were arrested, a witness said.

Mousavi, prime minister in the 1980s, attended the ceremony in his first official public appearance since the presidential vote, which he says was rigged. The authorities deny any fraud.

Rafsanjani, who heads the Council of Experts -- a powerful body that can in theory dismiss the supreme leader -- attacked the way authorities had handled the poll and its aftermath.

When people are not in the scene and their votes are not there, that government is not Islamic, he said, referring to opposition charges of vote-rigging. Today is a bitter day.

Rafsanjani said it was vital to restore voters' faith in the system. That trust cannot be brought back in a day or a night ... We have all been harmed, he added, calling for unity.

He criticized the Guardian Council, a clerical body which vets candidates and considers election complaints, for failing to do its job even though it was given five extra days to make its assessment. The council has denied any irregularities.

HARSH LANGUAGE

Using harsh language against the use of security forces to quell protests, Rafsanjani, who was a close aide to Iran's late revolutionary founder Ayatollah Ruhollah Khomeini, said:

I speak as a person who has been with the revolution on a daily basis ... We knew what Imam Khomeini wanted. He didn't want the use of terror or arms, even in fights (for the revolution).

The election stirred the most striking display of internal unrest in Iran, the world's fifth biggest oil exporter, since the 1979 revolution and exposed deep rifts in its ruling elite.

If the Islamic and Republican sides of the revolution are not preserved, it means we have forgotten the principles of the revolution, said Rafsanjani, who was enraged during the election campaign when Ahmadinejad accused him of corruption.

At least 20 people died in post-election violence. Mousavi and the authorities blame each other for the bloodshed. Riot police and religious Basij militia eventually suppressed the street demonstrations, but Mousavi has remained defiant.

Rafsanjani also demanded the immediate release of people detained in the unrest and called for press curbs to be relaxed. Some of his own relatives, including his daughter Faezeh, were arrested briefly for joining pro-Mousavi rallies.

It is not necessary for us to have a number of people in prisons ... we should allow them to return to their families, he said, in an emotional tone. It is not necessary to pressure media. We should allow them to work freely within the law.

Earlier people inside the hall could be heard chanting Mousavi, Mousavi, we support you, briefly interrupting Rafsanjani's sermon before he quieted the crowd.

Rafsanjani's robust stance appeared to set him on collision course with Khamenei, who has overtly backed Ahmadinejad in a departure from the supreme leader's accepted role as a lofty clerical arbiter above the political fray.

The election has further strained ties between Iran and the West, already at odds over Tehran's nuclear program. Western powers criticized the crackdown. Iran accused them of meddling.

(Additional reporting by Zahra Hosseinian; writing by Alistair Lyon)