Please contribute generously in order to ensure the continuity of our website InshaAllah.
Praise be to Allah.
Firstly:
If someone refrains from committing a sin, then he must be refraining for one of the following reasons:
Ibn Rajab said: But if he thinks of committing a sin then refrains from doing it out of fear of people, or to show off to them, then it was said that he will be punished for refraining from sin with this intention, because giving precedence to fear of people over fear of Allah is forbidden. Similarly, intending to show off to people is also forbidden. So if that (showing off) is combined with refraining from sin for that purpose, he will be punished for refraining.
End quote from Jaami‘ al-‘Uloom wa’l-Hikam (2/321).
Ibn al-Qayyim al-Jawziyyah (may Allah have mercy on him) said: … If someone refrains from (sin) for the sake of something other than Allah and not for the sake of Allah, he will be punished for refraining for the sake of something other than Allah, just as he would be punished for doing it for the sake of something other than Allah. This restraint and refraining is one of the deeds of the heart, and if it is done as an act of worship for something other than Allah, then he deserves punishment.
End quote from Shifaa’ al-‘Aleel, p. 170
Ibn al-Qayyim (may Allah have mercy on him) said – differentiating between this case and the previous one: If it is said: how can he be punished for refraining from sin to avoid embarrassment before people and to preserve his status among them, and for fear that they turn against him, when Allah, may He be glorified, does not condemn that or disallow it?
The answer is: undoubtedly he will not be punished for that. Rather he may be punished for seeking to draw closer to people by refraining from that sin and showing off to them thereby, so that they think that he refrained from it for fear of Allah and knowing that He is watching, when in reality that was not the case. So there is a difference between refraining from sin in order to draw closer to people and to show off to them, and refraining from sin to avoid embarrassment before them, and fear of their harm and that he may lose respect in their eyes. In this case he will not be punished for it; in fact he may be rewarded for it, if he did that for a purpose that Allah loves, such as upholding the status of the caller to Allah, and so that people will continue to listen to him and benefit thereby, and so on.
End quote from Shifa’ al-‘Aleel, p. 170
Shaykh al-Islam Ibn Taymiyah (may Allah have mercy on him) said: This is the one who thinks of committing a bad deed, then he refrains from it either out of fear of Allah, or for some other reason. If he refrains from it out of fear of Allah, Allah will record an entire hasanah with Him for him, as is clearly stated in the hadith, and as it says in another hadith: “Record for him one hasanah, for He only refrained from it for My sake.”
Or he refrained from it for some other reason, in which case no bad deed will be recorded against him, as it says in another hadith: “If he does not do it, nothing will be recorded against him.” Thus the meanings of the different reports on this topic may be reconciled.
End quote from Majmoo‘ al-Fataawa (10/738).
Secondly:
Acts of worship are not accepted from the Muslim unless two conditions are fulfilled:
The evidence for these two conditions is the verse in which Allah, may He be exalted, says (interpretation of the meaning):
“So whoever would hope for the meeting with his Lord - let him do righteous work and not associate in the worship of his Lord anyone”
[al-Kahf 18:110].
Based on that, if a child prays for fear of his father or seeking to please his father, and does not intend alongside that to please Allah, then his prayer is not accepted, because prayer is an act of worship, and worship can only be done for Allah.
But if he intends in his prayer – which is usually the case – to please Allah, then to please his parents as a secondary objective, then in this case his prayer will be accepted, in sha Allah.
And Allah knows best.