"The victory in Aleppo... constitutes a great victory for the Syrian people against terrorists and those who support them," Rouhani told Assad.
The Syrian leader reportedly responded that Iran had stood "on the side of the Syrian people and government in its most difficult moments, and we will never forget it".
Iran has not committed its regular army to the Syrian conflict, but its paramilitary Revolutionary Guards have played a crucial coordinating role.
Thousands of Iranian volunteers -- many of them motivated by a desire to protect Shiite shrines in Syria -- are thought to have fought on the frontline.
With just a small pocket of rebel resistance left in Aleppo, Tehran officials say the offensive has underlined Iran's growing regional clout.
Signup to our newsletter and follow us on Facebook and Twitter!
"The coalition between Iran, Russia, Syria and (Tehran-backed Lebanese militant group) Hezbollah led to the liberation of Aleppo and will next liberate Mosul (in Iraq)," said Yahya Safavi, top foreign policy adviser to Iran's supreme leader Ayatollah Ali Khamenei.
Safavi, a former head of the Revolutionary Guards, said a clear message was being sent to the incoming US president, Donald Trump, who has vowed to take a tougher line with Iran.
"The new American president must accept the reality that Iran is the leading power in the region," the Guards' Sepahnews website quoted him as saying.
Iran accuses the United States and its allies of supporting "terrorists" in Syria.
Fresh panels have sprung up around Tehran, with one reading: "The fight against the United States has once again paid off. Aleppo is liberated."
Western governments counter that Assad is responsible for the deaths of hundreds of thousands of his own people in more than five years of conflict in Syria.