According to the spokesman for the governor of Herat province, Hameedullah Motawakel, at least 18 people were killed and 23 others injured.
Afghanistan: UN Urged To Defend Rights of Women and Girls
Among the dead was Imam Mujib Rahman Ansari, Herat police spokesman Mahmoud Rasooli said, noting that some of his guards and civilians were killed on their way to the mosque.
For his part, Taliban spokesman Zabihullah Mujahid said that "the country's strong and courageous religious scholar was martyred in a brutal attack" and called for the attack's perpetrators to be punished.
The assassination of the pro-Taliban scholar is the second in less than a month. Rahimullah Haqqani was also a fatality in a suicide bombing at his madrassa in Kabul. ISIS later claimed responsibility for this attack.
Afghanistan has suffered several attacks in recent months, although the Taliban argue that security in the country has improved after they took power around a year ago.
ISIS has launched several suicide bombings during Friday prayers, mainly targeting Shia Muslims.
Followers of Sunni Islam, the mainstream Islam in Afghanistan also followed by the Taliban, are attracted to the mosque in Herat. Although a Sunni Islamist group, ISIS maintains rivalry and ideological differences with the Taliban.