However, there have been reports that reformist leader and former president Mohammad Khatami was banned from attending Tuesday's event.

Rafsanjani, who died of a heart attack on Sunday at the age of 82, will be buried inside the crypt of Ruhollah Khomeini, the leader of Iran's 1979 Islamic revolution, according to Al Jazeera's Dorsa Jabari, who is reporting from the Iranian capital.

"It's a very sombre occasion in the Islamic Republic," Jabari said. "This was something very unexpected. Many ordinary people, who weren't necessarily even fans of Rafsanjani, or his family, expressed their views that they were just shocked and extremely saddened by the loss."

Khomeini's mausoleum is in south Tehran near the capital's largest airport.

Leaders of all of Iran's competing political factions also attended the funeral.

Black banners were raised in Tehran and some posters showed the supreme leader and Rafsanjani together smiling. Another poster said "Goodbye, old combatant".

Authorities have declared Tuesday a public holiday so Iranians can commemorate Rafsanjani.