The speech was a rare public address by Khamenei, who usually only speaks in public at the end of Ramadan and the anniversary of the Iranian revolution, which brought the theocracy to power.
'Enough is enough'
"Candidates were put forward into public eye, everyone could judge for themselves ... they have identified the person they wanted," he said, adding the result was an "absolute and definitive victory".
"The Islamic establishment will never manipulate people's votes and commit treason ... the legal structures and electoral regulations of this country do not allow vote rigging," he said in his first public address on the issue since the election.
Farzad Agha, an Iranian analyst, told Al Jazeera: "This clearly is a threat to the demonstrators and supporters of the opposition candidates ... He is saying, 'if you continue, we will deal with you'."
Robert Fisk, a correspondent with the UK-based Independent newspaper, said Khamenei's message to the demonstrators seemed to be "enough is enough".
"He clearly wants them to obey him and go home," Fisk said.
Khamenei called for calm following days of protests over the election results.
"When you have peace of mind and soul you can decide wisely ... Today our society is in need of peace and tranquility," he said.
"Since the beginning of the Islamic revolution 30 years ago ... various incidents [occurred], some of which could have toppled the establishment, which could have brought turmoil to the nation, as you have seen in other nations.
"But in this nation which is moving firmly ... this ship did not find any agitation in stormy sea.
"I do believe with the help of God this nation will reach all of its high objectives."
Despite some protesters saying that a march was planned from Tehran's Revolution Square to Freedom Square on Saturday, Mir Hossein Mousavi, a defeated presidential candidate, said there was no demonstration scheduled in the coming days.
"Mousavi has no plans to hold a rally tomorrow or the day after tomorrow and if he decides to hold a rally it will be announced on his website," an unnamed ally told the Reuters news agency.
Khamenei said that the "great accomplishment" of the 85 per cent turnout at the polls conveyed the legitimacy of the country's leadership and "people's solidarity with their establishment".
"If people do not feel free they will not attend the voting stations, trusting the Islamic establishment was evident in this vote."
Khamenei said that foreign media were trying to say that the poll was a fight between inside and outside the establishment, which he denied, saying, "It is only differences of opinion within the establishment."
"The enemies [of Iran] know that without confidence there would be low turnout. When there is low turnout then the legitimacy would be in doubt. That is what the enemy wants."
He said that Iran's enemies had made allegations that the elections were rigged to harm the ruling system.
"The enemies [of Iran] are targeting the Islamic establishment's legitimacy by questioning the election and its authenticity before and after [the vote]," Khamenei said.
Thousands of people massed outside the packed hall and cheered Khamenei.
Al Jazeera's Alireza Ronaghi, reporting from Tehran, said that the huge crowds at Tehran University "were his staunchest supporters".
"They were smiling most of the time and also cried when he said he was willing to give his life for the Islamic revolution.
|Daily protests have been held since the poll results were released [AFP/TWITPIC]
"They chanted slogans several times, interrupting the supreme leader's speech, and in some cases he had to stop them and ask them to listen," he said.
Khamenei has the final say in all of Iran's affairs under the constitution, and thus has the authority to annul elections and establish new polls.
The sermon was delivered amid reports of a developing split between Khamenei and Ayatollah Hashemi Rafsanjani, who heads the powerful Assembly of Experts, which, in theory, has the constitutional right to replace the supreme leader.
Iran has been in a state of political unrest since Ahmadinejad was declared the winner.
Opposition figures, led by Ahmadinejad's main challenger Mir Hossein Mousavi, have said that the vote was rigged and hundreds of thousands of Iranians have held daily street protests since the poll results were announced.
Amnesty International, a UK-based human rights group, said on Friday that it believed 15 people had been killed as the protests have spilled over into violence, compared with just seven deaths reported on Iranian state radio.
The protests have continued despite the Guardian Council - a body of top Iranian clerics - saying it was investigating 646 complaints of poll violations submitted by Mousavi and two other defeated presidential candidates.
The council, which oversees elections, has also invited the trio of defeated candidates to set out their grievances on Saturday, with a decision about any possible recount of the vote expected on Sunday.