This article provides a short summary of the topic of how the living may benefit the dead. For a more detailed read, please refer to Things that Benefit the Dead by Muhammad al-Jibaly.
The Qur'an established two general principles concerning the reward and punishment for deeds:
Firstly, that each human will fundamentally only be benefited or harmed by the deeds which he or she actually did.
" ... humans will only have the result of their own actions."
Secondly, that no human can carry the sin of another.
" ... no one bearing sins can carry the sins of others."
Consequently, when a person dies, the opportunity for that person to do good ends with the person's death. However, the chance to harvest good from deeds which were done prior to death remains.
The prayers of other Muslims on behalf of the dead will benefit the dead, by the permission of God. Had they done no good, no one would consider praying for them. If they were evil, the prayers of others will not benefit them. Allah praises the believers who pray for those who have passed away before their time:
"And those who came after them say: Our Lord, forgive us and our brothers who preceded us in faith, and do not put in our hearts any hatred against the believers. Our Lord, You are indeed full of kindness, Most Merciful."
Furthermore, the funeral prayer itself consists mostly of prayers for the dead.
Safwan (the narrator mentioned that Safwan ibn 'Abdillah ibn Safwan was married to Ad-Darda) said:
"I visited Abu'd-Darda's home in Syria, but did not find him there. Ummu'd-Darda asked [me], 'Are you going to make Hajj this year?' I said: 'Yes.' She said, 'Pray to Allah for good for us, for the Prophet, upon whom be peace, said, 'The prayer of Muslim for his Muslim brother in his absence will be answered. As long as he prays for the good of his brother, there is an angel assigned near his head who says: amen, and may the same be for you.'' I left and went to the marketplace where I met Abu'd-Darda and he related from the Prophet, peace be upon him, the same as that."
Fasts missed by dead persons may be done on their behalf by their close relatives. The fasts may be from Ramadan or from oaths (nathar). 'A'ishah quoted Allah's Messenger, peace be upon him, as saying:
"Whoever died owing fasts, his guardian should fast on his behalf."
Ibn 'Abbas related that a man came to the Prophet, upon whom be peace, and asked: O Messenger of Allah, my mother died owing one month of fasting. Should I do it for her? He replied:
"Yes, debts to Allah have more right to be paid."
In another narration (Sahih Muslim, vol. 2, pp. 556-7, nos. 2554, 2557-61) a woman asked about her mother’s debt of fasting and got the same reply.
Paying Financial Debts
Anyone may cover the debts of a dead person, whether they are relatives or not. Furthermore, the payment of outstanding debts can benefit the dead by relieving them from some of the punishment due to them for their negligence in repaying them.
Jabir narrated that a man died and they washed him, perfumed him and shrouded him. Then he was brought to Allah's Messenger, peace be upon him, to lead the funeral prayer for him. They asked, "Could you pray for him?" He took a step forward then asked, "Does he have any outstanding debts?" It was answered: "Two dinar." He said: "Make the funeral prayer for your companion," and began to leave. Abu Qatadah took responsibility for [paying] the debt, saying, "The two dinar are my responsibility." Allah's Messenger, peace be upon him, asked, "Will the creditor be taken care of and will the dead person be absolved from them?" He replied, "Yes," so the Prophet, upon whom be peace, led the funeral prayer for him. A day later he asked Abu Qatadah, "What was done about the two dinar?" He replied, "He only died yesterday!" The following day he returned to the Prophet and said, "I have paid them off." The Messenger of Allah, peace be upon him, said, "Now his skin has become cool."
The Charity of Children
Parents will benefit from whatever righteous deeds their children do, without decreasing the reward of their children's good deeds. A righteous child is considered to be part of the parent's earnings.
'Umarah ibn 'Umayr's aunt asked 'A'ishah, "I have an orphan under my guardianship. May I consume some of his wealth?" She replied that she had heard Allah's Messenger, peace be upon him, say:
"Among the most pleasant things a man consumes is what comes from his own earnings, and his child is from his earnings."
'A'ishah related that a man asked the Prophet: My mother died suddenly, and I think that if she had spoken [before dying], she would have given something in charity. If I give charity on her behalf, will she get the reward? He replied:
Abu Hurayrah quoted the Messenger of Allah, upon whom be peace, as saying:
"When a man dies, his acts come to an end, except in three cases: an ongoing charity, knowledge from which people continue to benefit, and a righteous child who prays for him."