Iran's supreme leader Ayatollah Ali Khamenei prayed over the coffin containing the remains of top military commander Qasem Soleimeni in an emotional ceremony in Tehran on Monday.
Hundreds of thousands gathered in Tehran's Enghelab Square for the funeral procession for Soleimani, who was killed in a US airstrike in Baghdad.
Tehran police chief Gen. Hossein Rahimi said millions attended the farewell ceremony, though that number could not be verified.
The caskets of Gen. Qassem Soleimani, the Iraqi commander Abu Mahdi al-Muhandis and others were driven on a truck amid the huge crowd.
Soleimani was killed in a US drone strike near Baghdad international airport, shocking the Islamic republic and raising fears of a new war in the Middle East.
Mourners threw flowers and chanted "death to America and Israel", setting fire to flags of both countries.
The targeted killing of Soleimani already has seen his replacement vow to take revenge.
Additionally, Tehran has abandoned the remaining limits of its 2015 nuclear deal with world powers in response to the slaying while in Iraq, the parliament has called for the expulsion of all American troops from Iraqi soil.
The developments could bring Iran closer to building an atomic bomb, set off a proxy or military attack launched by Tehran against America and enable the Islamic State group to stage a comeback in Iraq, making the Middle East a far more dangerous and unstable place.