It is reported that Al-Fuḍayl b. ‘Ayyāḍ – Allāh have mercy on him – said, “If I had one supplication that was going to be answered I would make it for the ruler (imām), for the wellbeing and righteousness of the imām means wellbeing for the land and its people.”
Al-Dhahabī, Siyar A’lām Al-Nubalā` in his biography of Al-Fuḍayl b. ‘Ayyāḍ.
Points to note
Wanting good for the Muslim rulers and supplicating to Allāh for them features as an important aspect of the creed of Ahl Al-Sunnah wa Al-Jamāah, and distinguishes them from the extremist ideology of the Khawārij sect. This has been recorded in the classical works of Sunni ‘aqīdah, for example:
Al-Barbahārī (Sharḥ Al-Sunnah p113, 114) states, “If you see a man supplicating against the ruler, know that he is a heretic (ṣaḥib hawā), and if you see a man supplicating for the ruler, know that he is a Sunni – inshā Allāh.”
Al-Imām Al-Ājurrī (d360H) states (Al-Sharī’ah Vol.1 p371), “I have mentioned warnings against the ways of the Khawārij that convey the message for everyone who Allāh protects against the ways of the Khawārij, and who does not hold the views of the Khawārij, but is [instead] patient over the injustice of the rulers … and who prays for the wellbeing and righteousness of the rulers, and who does Hajj and Jihād behind the rulers against every enemy of the Muslims, and who prays the Jumu’ah and ‘Eid prayers behind the rulers. Whoever fits this description is upon the Straight Path – inshā Allāh.”