Some in the funeral procession held aloft the green banners of the opposition movement, while others chanted anti-government slogans.
Security forces were present along the route, and there are reports of isolated fighting between some of the police and protesters.
The crowds came from across Iran to the holy city of Qom to attend the burial of Ayatollah Montazeri. Iranian authorities banned foreign media coverage of the event. But opposition websites and videos posted online gave an idea of the extent of the gathering.
The ayatollah was buried in the shrine of Masoumeh. Opposition leaders Mir Hossein Mousavi and Mehdi Karroubi called for a day of mourning and had urged supporters to come to the funeral.
Opposition groups report at least one busload of people trying to reach Qom was turned back, while there were other reports of arrests. There was no immediate government or independent confirmation of such incidents or the reports of fighting between protesters and security forces in Qom.
The Iranian government and state media initially downplayed the popular cleric's death. On Monday, Foreign Minister Manouchehr Mottaki paid tribute to Montazeri.
Mottaki, on a visit to Beirut, said the late ayatollah was a great scholar and asked for God's forgiveness and mercy for him.
Montazeri was one of the founding fathers of the Islamic Republic and remained a top arbiter of Shi'ite law. But his criticism of what he saw
as authoritarianism and human-rights abuses led to his being dropped as successor to the nation's Supreme Leader.
The ayatollah continued his opposition from Qom, where he spent several years under house arrest for his outspoken views. This year he played a critical role in condemning the government after the disputed re-election of President Mahmoud Ahmadinejad and a subsequent crackdown on opposition supporters.
Security was already tight as Iranians observe an annual period of mourning. Such events have been used by opposition supporters to protest against the government.
Observers note the first week commemoration of Montazeri's death Sunday will coincide with the marking of the solemn Ashoura holiday.
Iranian Cleric's Funeral Turns Into Anti-Government Protest