State television showed people pouring on to the streets around the campus where Ayatollah Ali Khamenei will lead the eulogies for Rafsanjani despite their "differences".
The heavyweight politician, who died on Sunday at the age of 82, will be buried inside the crypt of Ayatollah Ruhollah Khomeini, the leader of Iran's 1979 Islamic revolution.
Khomeini's mausoleum is in south Tehran.
Leaders of all of Iran's competing political factions were expected to attend the funeral.
Black banners were raised in Tehran and some posters showed the supreme leader and Rafsanjani together smiling. Another poster said "good bye, old combatant".Free bus or metro travel was provided to the funeral venue.
Mourners gather around the coffin of former Iranian President Akbar Hashemi Rafsanjai, during a mourning ceremony in Tehran, Iran, 09 January 2017. (AAP) Source: EPA
Since Rafsanjani's death, messages of condolences have poured in both from at home and and abroad.
Even the White House sent a message, unprecedented since the 1979 revolution that led to cutting of ties between Tehran and Washington.
"Former president Rafsanjani was a prominent figure throughout the history of the Islamic Republic of Iran and the United States sends our condolences to his family and loved ones," spokesman Josh Ernest said.
"He was a consequential figure inside Iran. But you know, for what potential impact this could have on Iranian policy, I wouldn't speculate."