'The Prophet (Sallalahu alahy wa sallam) said: ‘Whoever notices in his ruler what he dislikes, he should show patience’ - he should show patience, he should bear it, he should not oppose him nor should he talk – ‘because he who departs from the (Muslim) Community, dies like as it was in days of Jaahiliyyah.' That is, not a death in Islâm. In Allâh we seek protection.
This has two meanings:
One: That he dies in Jaahiliyyah meaning that his heart has derailed, in Allâh we seek refuge, such that it is this sin (of quitting the Muslim Community because of talking about the rulers) that causes his straying from the path.
Two: It could be the second meaning that he dies as the death in Jaahiliyyah, because the people of Jaahiliyyah did not have a ruler or a leader. Though they had heads and chiefs who did not have authority as it is in Islam. So the person’s death will be like that.
The point is that we must hear and obey the ruler except in one situation – when they command us to disobey the Creator, then we will not obey them. If they ask us to shave our beard or trail our clothes or trousers (below the ankles), or that we should not observe the Salat (again), or that we should not fast in Ramadan, then we will not obey them in all these. Any sin they command us of, we will not hear and obey them no matter who might be. But when they command of anything that is not sinful them we must obey them.
Two: It is not permissible for us to oppose the leaders.
Three: It is not permissible for us to discuss in the Ummah what may cause an uprising against the ruler, or what can cause hatred towards them, because this will cause a great evil. Some people might think that they do that to show their feeling, and that they are expressing the truth (Al-Amr Bil'Ma'ruf). But saying the truth ought not to be behind the veil, it should be before the ruler whereby you will tell him face-flat: ‘You did such-and-such which is not good; you left such-and-such obligation’.
But for you to talk behind the veil whereby you abuse the ruler and you become famous for that (in Allâh we seek refuge), this is not saying the truth, rather it is causing evil, which can lead to hatred towards the ruler and rising against them. This can even lead to what is greater in evil which is carrying out an armed struggle against them to oust them from power and tearing the oath of allegiance in the process. In Allâh we seek refuge.
We should be careful in matters like this, and we should sail as the People of Sunnah and the Community (Ahlus-Sunnah Wal Jamaa'ah) had sailed. Whoever wants to know that let him read the books of Sunnah that has been written on matters like this, such will find out how the Imams that had been in this Ummah used to extol the leaders; he would see how they used to establish what the Messenger of Allâh (Sallalahu alahy wa sallam) had commanded of as regard not opposing the rulers, and showing them obedience in what is not a sin.
Shaykul-Islâm Ibn Taymiyyah (may Allah show mercy on him) mentioned towards the end of his book, Aqeedatu-Waasitiyyah – this is a small (book) of Aqeedah (creed) but whose meaning is wider than what is written down in the book; the Imam mentioned that it is part of the Creed Ahlu-Sunnah Wal Jamaah that they owe allegiance to the rulers, that they see the obligation of carrying out the Hajj, Jihâd, festivals, and praying in congregation with the leaders whether they are just or unjust. To the extent that if the ruler was unjust, the People of Sunnah and the Community see the obligation of carrying out the Jihâd, Hajj, prayer in congregation and observance of the festivals with him.
Unless if we see a clear-cut unbelief (Kufrun Bawaah) which we have a justification for from Allah – the Mighty and Sublime, then it becomes obligatory on us, as our capacity will allow us, to remove this ruler; we should replace him with someone who is better than he is. As for other sins that the leader may commit, the People of Sunnah and Community see the obligation of obedience to the ruler even as regards the matters mentioned earlier on (in the earlier chapters); that he must be obeyed not opposed, not sensitizing the people against him, or in any other way which greater evil can be caused.
Evil cannot be repelled with evil, rather repel evil with good. As for repelling evil with evil, if they are alike then it has no benefit but if it turns out to be more evil, as it used to be, then that is a greater evil.
We ask Allah – the Mighty and Sublime – to guide our rulers and their subjects towards their duties, and that He should facilitate each on what is expected of them.' End of quote.
Ash-Shaykh Muhammad Saalih Al-Uthaymeen in his commentary on hadith 670 of Riyyadus-Saaliheen of al-Imam an-Nawawi, may Allaah bestow mercy on both.