May Allāh bless you. [The one with this question] says: How does a sincere intention in [one’s] actions come about, O esteemed shaikh?
Purifying intentions for deeds is [with] a person making himself forget everything other than Allāh and nothing making him perform this act of worship other than to conform with Allāh’s command, Almighty and All-Majestic is He, and to seek His reward and His pleasure; and his making himself forget everything connected to this world in [doing] this act of worship, so he is not concerned with people–did they see him or not see him, did they hear him or not hear him–and he does not give them a thought, [whether] they praised him or found fault with him.
And similarly, also, from that which leads to purity [of intentions] is a person, when carrying out [some] act of worship, keeping in mind Allāh’s having commanded it, Almighty and All-Majestic is He, and keeping in mind [his] following the Messenger ﷺ in [doing] it.
An example of that is a man who has gotten up to make ablution for prayer. So here we say: First, keep in mind that you have only gotten up– yes, keep in mind that you have only performed ablution conforming with Allāh’s command, Almighty and All-Majestic is He, as if you are reciting Allāh the All-High’s saying:
O you who have believed, when you [are to] stand for prayer, wash your faces and arms [from your hands] up to [and including] your elbows, wipe over your heads, and [wash] your feet up to [and including] your ankles. [English meaning of Al-Mā’idah: 6]
And [put in your mind that it] as if you are saying, while performing ablution: “[I] hear and obey.” You will then find a sweetness, pleasure and love for entering a state of ritual purity, since Allāh commanded you with it.
After that, keep in mind that you are, in [performing] this deed, following the Messenger ﷺ as if the Messenger ﷺ were in front of you and you were following him in [performing] this ablution.
With this, the reward and compensation [from Allāh] for purity of intention and proper conformity become established for you. And with that, you actualize the testimony that no one is deserving of being worshipped other than Allāh and that Muḥammad ﷺ is His messenger. Yes.