On what should be said when a Person Dies
Riyad as-Salihin (Gardens of the Righteous)
Riyad as-Salihin 924
Umm Salamah relates that the Holy Prophet said: When you visit an invalid or one just dead say only that which is good, for the angels say Amen to whatever you say. She adds: When Abu Salamah died I came to the Holy Prophet and said: Messenger of Allah (saw), Abu Salamah has died. He directed me: Supplicate: Allah, do forgive me and him and bestow upon me a better future. I supplicated as he had directed, and Allah bestowed upon me one better than he, even Muhammad (Muslim).
Riyad as-Salihin 925
Umm Salamah relates: I heard the Holy Prophet say: When a person is afflicted by misfortune and supplicates: To Allah we belong and to Him shall we return; Allah compensate me in my misfortune and bestow upon me better than that which I have lost; Allah compensates him in his misfortune and bestows upon him better than he has lost. Umm Salamah adds: When Abu Salamah died, I supplicated as the Holy Prophet had directed and indeed Allah bestowed upon me better than him whom I had lost, that is to say, I was asked in marriage by the Holy Prophet (Muslim).
Riyad as-Salihin 926
Abu Sa‘ad relates that the Holy Prophet said: When a child of a servant of Allah dies, Allah inquires from His angels: Have you taken into custody the soul of the child of My servant? They answer: Yes. Then He inquires: Have you taken into custody the soul of the flower of his heart? They answer: Yes. Then He inquires: Then what did My servant say? They answer: He praised Thee and affirmed: To Allah we belong and to Him we shall return. On which Allah will say: Build for My servant a mansion in Paradise and name it: The House of Praise (Tirmidhi).
Riyad as-Salihin 927
Abu Hurairah relates that the Holy Prophet said: Allah, the Exalted, says: I have no reward other than Paradise for a believing servant of mine who is steadfast when I take away a beloved one of his from among the denizens of the world (Bokhari).
Riyad as-Salihin 928
Usamah ibn Zaid, loved by the Holy Prophet and the son of one loved by him, relates that a daughter of the Holy Prophet sent word to him that her son was at his last breath and begged him to go to her. He sent his salutation to her with the message: To Allah belongs that which He bestowed and to Him belongs that which He takes. Everything has its term fixed by Him. Let her be steadfast, therefore, and hope for His grace and mercy. She sent back word to him begging him for the sake of Allah to go to her. He stood up and proceeded to her accompanied by Sa‘ad ibn Ubadah, Mu‘az ibn Jabal, Ubayy ibn Ka‘ab, Zaid ibn Thabit and others. When he arrived the child was presented to him and he took it in his lap. Observing its distress his tears began to run, whereupon Sa‘ad said: Messenger of Allah (saw), what is this? He made answer: This is compassion which Allah has placed in the hearts of His servants (and one version has it: in the hearts of such of His servants as He has willed) and Allah has compassion on such of His servants as are compassionate (Bokhari and Muslim).