Sure Ghafir

40:12

ذَٰلِكُم بِأَنَّهُۥٓ إِذَا دُعِىَ ٱللَّهُ وَحْدَهُۥ كَفَرْتُمْ ۖ وَإِن يُشْرَكْ بِهِۦ تُؤْمِنُوا۟ ۚ فَٱلْحُكْمُ لِلَّهِ ٱلْعَلِىِّ ٱلْكَبِيرِ

"Dies ist so, weil ihr, wenn (immer) Allah allein angerufen wurde, ungläubig bliebt, ihr aber, wenn Ihm (andere) beigesellt wurden, glaubtet. Das Urteil gehört Allah, dem Erhabenen und Großen."

Tafsir 40:12

That punishment which you are punished with is because when Allah was called upon and no partner was associated with Him, you disbelieved in Him and made partners for Him. And when partners were worshipped alongside Allah, you believed. So the judgment is with Allah alone, High with His essence, decree and domination, the Great.