Surah As-Saff

61:5

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

And [mention, O Muhammad], when Moses said to his people, "O my people, why do you harm me while you certainly know that I am the messenger of Allah to you?" And when they deviated, Allah caused their hearts to deviate. And Allah does not guide the defiantly disobedient people.

Tafsir 61:5

After Allah mentioned fighting and praised the believers who stand tightly together in fighting in His path, He mentioned the opposition that the people of Moses and Jesus displayed towards their messengers, as a warning to the believers against opposing their prophet, and He said: Remember, O Messenger, when Moses said to his people: O my people! Why do you hurt me by going against my instruction when you know that I am Allah’s messenger to you?! When they moved away and deviated from the truth that he brought to them, Allah caused their hearts to move away from the truth and steadfastness. Allah does not guide to the truth a people who go against His obedience.