عَنْ أُبَيِّ بْنِ كَعْبٍ رَضِيَ اللَّهُ عَنْهُ عَنِ النَّبِيِّ صَلَّى اللَّهُ عَلَيْهِ وَآلِهِ وَسَلَّمَ قَالَ: ((مَنْ تَبِعَ جَنَازَةً حَتَّى يُصَلَّى عَلَيْهَا وَيُفْرَغَ مِنْهَا فَلَهُ قِيرَاطَانِ، وَمَنْ تَبِعَ حَتَّى يُصَلَّى عَلَيْهَا فَلَهُ قِيرَاطٌ، وَالَّذِي نَفْسُ مُحَمَّدٍ بِيَدِهِ! لَهُوَ أَثْقَلُ فِي مِيزَانِهِ مِنْ أُحُدٍ))
It is narrated from Sayyiduna Ubayy ibn Ka'b (may Allah be pleased with him) that the Noble Prophet (peace and blessings be upon him) said: Whoever accompanies the deceased (and remains with him) until the funeral prayer and (burial) is completed, he will have the reward of two qirats. And whoever goes with him until the funeral prayer is completed, for him is the reward of one qirat. By the One in whose hand is the life of Muhammad (peace and blessings be upon him)! This qirat will be heavier on that person's scale than the mountain of Uhud.