Answered by Shaykh Faraz Rabbani
Question: Does one get rewarded for an act one does out of mere habit that corresponds to the sunna?
Answer: Walaikum assalam
The first legal maxim that Ibn Nujaym mentioned in his Ashbah wa’l Nadha’ir is: “There is no reward without intention.” This is one of the most repeated and well-known of legal maxims.
It is taken from the well-known hadith in which the Prophet (Allah bless him & give him peace) said, “Verily actions are by their intentions, and one shall only have that which one intended.” [Bukhari & Muslim] The scholars stated that there is something implicit in this hadith, namely: “Verily actions are [rewarded] by their intentions, and one shall only have [the reward] for that which one intended.”
Therefore, if one’s habits or whims are in conformity to the sunna of the Prophet of Allah (Allah bless him & give him peace), one should strive to have an intention in it for Allah. Otherwise, it remains a habit. The scholars say, “Through intentions habits become worship.” ( bi’l niyyaat tanqalibul `aadaat `ibaadaat)
Abd Allah ibn Mubarak (Allah be pleased with him), said, “How often it is that a small action becomes great by its intention. And how often it is that a great action becomes small by its intention.” [Dhahabi, Siyar A`lam al-Nubala’, 8: 400]