Any good deed that a Muslim starts during his lifetime, and that is of renewed benefit and ongoing use for others, will continue to benefit him and augment his record of good deeds, even after his departure – as long as its benefits continue to reach others.
“We record that (deeds) which they have put forward and their traces (that which they have left behind).” [Qur’an 36:12]
It is reported that
Prophet Muhammad (peace be upon him), said, “When a human being dies, all of his deeds are terminated except for three types: an ongoing sadaqah (charity), a knowledge from which others benefit, and a righteous child who makes du’a (supplication) for him.”
The reason that one continues to receive rewards for these deeds even though they are done by other people, is that he had initiated them during his life or contributed to them to a certain degree, whether little or large. Since Almighty God does not neglect an atom’s weight of deeds, He records these contributions for a person even after his death. Ramadan is an excellent month to earn more rewards by doing good deeds and by doing such actions that will be of benefit for years to come and even after one passes from this earth. In Ramadan the rewards for all good actions are multiplied manifold.