Mourners turned out in thousands in Mashhad, where they walked on foot as part of the vigil and held up their cell phones with their flashlights on, creating a massive sea of lights.
A gunman opened fire on pilgrims at Shah Cheragh Shrine in Shiraz on Wednesday, running through the halls and courtyards with an AK-47 and shooting at everyone who appeared on his path, including women and children.
Anti-terrorism forces responded to the scene, where they shot and injured the assailant. He later died of his wounds.
A second suspect was arrested on the scene, and a third is on the run. Police have launched a manhunt.
The Daesh terrorist group soon claimed responsibility for the attack.
Earlier on Saturday, funerals were held for the victims in Shiraz.