Abu al-Aswad said, I came to Medina when an epidemic had broken out. While I was sitting with Umar bin Al-Khattab a funeral procession passed by and the people praised the deceased. Umar said, “It has become necessary.” And another funeral procession passed by and the people praised the deceased. Umar said, “It has become necessary.” A third (funeral procession) passed by and the people spoke badly of the deceased. He said, “It has become necessary. I (Abu al-Aswad) asked, “O leader of the believers, what has become necessary?” He replied, I said the same as the Prophet ﷺ said, ‘Any Muslim in whose favour four people testify, Allah will admit him to Paradise.’ We said: Or three? He ﷺ said: ‘Or three.’ We said: Or two? He ﷺ said: ‘Or two.’ Then we did not ask him ﷺ about one. (Sahih al-Bukhari, 1368).
The Hadith about praising the dead (above) is explained by scholars as referring to praise that is truthful and reflective of reality.
هَل يخْتَص الثَّنَاء الَّذِي ينفع الْمَيِّت بِكَوْنِهِ مِمَّن خالطه وَعرف حَاله أم هُوَ على عُمُومه؟ قلت: الظَّاهِر الأول. (عمدة القاري شرح صحيح البخاري).
And is the beneficial praise only considered if it comes from someone who mixed with him knew his state? Or is it general (and inclusive of others too). The sounder opinion is the first. (Imam Badr al-Din al-Ayni, Umdatu al-Qari).
It is also necessary to keep in mind that the praise must be regarding matters that one is permitted to comment upon, for example outward piety, character, and knowledge. Not regarding matters that are known to Allah (Most High) alone, like inward piety, rank, and status with Allah (Most High). Such matters are from the Ghayb (unseen) and thus not permitted to speak of without evidence from Quran and Hadith.
الْمَرْأَة الَّتِي أثنت على عُثْمَان بن مَظْعُون بقولِهَا: شهادتي عَلَيْك أَبَا السَّائِب، فَقَالَ لَهَا: وَمَا يدْريك؟ وَقد يُجَاب عَنهُ: بِأَنَّهُ إِنَّمَا أنكر عَلَيْهَا الْقطع بِأَن الله أكْرمه، وَذَلِكَ مغيب عَنْهَا، بِخِلَاف الشَّهَادَة للْمَيت بأفعاله الجميلة الَّتِي كَانَ متلبسا بهَا فِي الْحَيَاة الدُّنْيَا. (عمدة القاري شرح صحيح البخاري).
(As for) the woman who praised Uthman bin Madhoon saying, my testimony for you O Aba al-Saib (is that Allah Most High has honored you). He (The Prophet ﷺ) said to her, how do you know? This can be explained by saying, He ﷺ reproached her for it because of her saying definitively that Allah (Most High) has honoured him. And that is from the unseen. As opposed to (mentioning) the virtuous actions of the deceased that he used to be involved in during his worldly life. (Imam Badr al-Din al-Ayni, Umdatu al-Qari).
In the Nass (text) above, Imam al-Ayn makes it very clear that we cannot comment on a person’s state with Allah (Most High). Commenting on such matters is speaking of the Ghayb without evidence and is rebuked in the Hadith. Despite such clear explanations from classical scholars and abundant evidence from Quran and Hadith many Muslims persist in such errors.
And Allah (Most High) knows best.
– Answered by Shaykh Noorud-deen Rashid (25.09.2021)