Thus Allah—exalted is He—has deemed obedience to the devils and their confederates in declaring lawful what He has forbidden to be an act of shirk with Him. Likewise, anyone who follows scholars or rulers in forbidding what Allah has made lawful, or permitting what Allah has made unlawful, has taken them as lords besides Allah, for He says: “They have taken their rabbis and monks as lords instead of Allah, as well as the Messiah son of Mary, while they were commanded to worship only one God—there is no god but Him. Glory be to Him above what they associate.” (9:31)
Al-Tirmidhī and others relate that the Prophet ﷺ recited this verse to ʿAdī ibn Ḥātim al-Ṭāʾī (may Allah be pleased with him). ʿAdī said, “Messenger of Allah, we did not worship them.” The Prophet ﷺ replied, “Did they not declare permissible what Allah had forbidden, and so you regarded it as permissible? And did they not declare forbidden what Allah had permitted, and so you regarded it as forbidden?” He answered, “Indeed.” The Prophet ﷺ said, “That, then, was your worship of them.” (1)
Accordingly, obeying them in matters of declaring lawful and unlawful apart from Allah amounts to worshipping them and constitutes shirk—major shirk that nullifies the monotheism which is—