Mourners attend the funeral procession of Iran's slain supreme leader Ali Khamenei and members of his family in Tehran on Monday.

Vast crowds gathered for the funeral procession of Iran's slain supreme leader Ali Khamenei in Tehran on Monday, with authorities estimating millions were on the streets in numbers that could rival those of his predecessor's farewell nearly four decades ago.

Authorities have yet to give an official turnout figure but AFP images showed huge numbers stretching along major boulevards in the Iranian capital.

The ceremonies offer Iran an opportunity to project resilience after five weeks of war with the United States and Israel, although attention remains focused on Khamenei's successor, his son Mojtaba Khamenei, who has not appeared in public since taking power.

After lying in state for two days at Tehran's Grand Mosalla religious complex, the body of Khamenei -- who was killed on the first day of the Middle East war on February 28 -- began its journey through the capital accompanied by massive crowds.