Sunan Ibn Majah, Book 6, Hadith 1567 (In-Book)

It was narrated that ‘Awf bin Malik said: “I saw the Messenger of Allah offering the funeral prayer for a man among the Ansar, and I heard him say: ‘Allahumma salli ‘alayhi waghfirlahu warhamhu, wa ‘afihi wa’fu ‘anhu, waghsilhu bi ma’in wa thaljin wa baradin, wa naqqihi min adh-dhunubi wal-khataya kama yunaqqath-thawbul-abyadu minad-danas, wa abdilhu bi darihi daran khayran min darihi, wa ahlan khayran min ahlili, wa qihi fitnatal-qabri wa ‘adhaban-nar. (O Allah, send blessing upon him, forgive him, have mercy on him, keep him safe and sound, and pardon him; wash him with water and snow and hail, and cleanse him of sins just as a white garment is cleansed of dirt. Give him in exchange for his house that is better than his house, and a family that is better than his family. Protect him from the trial of the grave and the torment of the Fire).’”

حَدَّثَنَا يَحْيَى بْنُ حَكِيمٍ، حَدَّثَنَا أَبُو دَاوُدَ الطَّيَالِسِيُّ، حَدَّثَنَا فَرَجُ بْنُ الْفَضَالَةِ، حَدَّثَنِي عِصْمَةُ بْنُ رَاشِدٍ، عَنْ حَبِيبِ بْنِ عُبَيْدٍ، عَنْ عَوْفِ بْنِ مَالِكٍ، قَالَ شَهِدْتُ رَسُولَ اللَّهِ ـ صلى الله عليه وسلم ـ صَلَّى عَلَى رَجُلٍ مِنَ الأَنْصَارِ فَسَمِعْتُهُ يَقُولُ ‏ "‏ اللَّهُمَّ صَلِّ عَلَيْهِ وَاغْفِرْ لَهُ وَارْحَمْهُ وَعَافِهِ وَاعْفُ عَنْهُ وَاغْسِلْهُ بِمَاءٍ وَثَلْجٍ وَبَرَدٍ وَنَقِّهِ مِنَ الذُّنُوبِ وَالْخَطَايَا كَمَا يُنَقَّى الثَّوْبُ الأَبْيَضُ مِنَ الدَّنَسِ وَأَبْدِلْهُ بِدَارِهِ دَارًا خَيْرًا مِنْ دَارِهِ وَأَهْلاً خَيْرًا مِنْ أَهْلِهِ وَقِهِ فِتْنَةَ الْقَبْرِ وَعَذَابَ النَّارِ ‏" ‏ ‏.‏ قَالَ عَوْفٌ فَلَقَدْ رَأَيْتُنِي فِي مُقَامِي ذَلِكَ أَتَمَنَّى أَنْ أَكُونَ مَكَانَ ذَلِكَ الرَّجُلِ ‏.‏

sunnah.com