Al-Sha’bi reported: Umm al-Harith bint Abi Rabi’ah died and she was a Christian woman. Her funeral was accompanied by the companions of Muhammad, peace and blessings be upon him.
Sufyan al-Thawri said in some narrations, “It was commanded that they should walk in front of her.”
Source: Muṣannaf ‘Abd al-Razzāq 9694
Al-Nawawi said, “Our scholars said it is not discouraged for a Muslim to follow the funeral procession of a relative who is an unbeliever… Rather, it is recommended to think about death, what comes after it, the passing of the world, and so on.”
Source: Rawḍat al-Ṭālibīn 2/116
عَنِ الشَّعْبِيِّ قَالَ مَاتَتَ أُمُّ الْحَارِثِ بْنِ أَبِي رَبِيعَةَ وكَانَتْ نَصْرَانِيَّةً فَشَيَّعَهَا أَصْحَابُ مُحَمَّدٍ صَلَّى اللَّهُ عَلَيْهِ وسَلَّمَ
قَالَ الثَّوْرِيُّ فِي بَعْضِ الْحَدِيثِ إِنَّهُ كَانَ يُؤْمَرُ أَنْ يَمْشِيَ أَمَامَهَا
9694 مصنف عبد الرزاق كتاب أهل الكتاب اتباع المسلم جنازة الكافر
قال النووي قَالَ أَصْحَابُنَا وَلَا يُكْرَهُ لِلْمُسْلِمِ اتِّبَاعُ جِنَازَةِ قَرِيبِهِ الْكَافِرِ … بَلِ الْمُسْتَحَبُّ الْفِكْرُ فِي الْمَوْتِ وَمَا بَعْدَهُ وَفَنَاءِ الدُّنْيَا وَنَحْوِ ذَلِكَ
2/116 روضة الطالبين وعمدة المفتين