عن أبي جُرَيٍّ الْهُجَيْمِيِّ رضي الله عنه قال: أتيت رسول الله صلى الله عليه وسلم فقلت: عليك السلام يا رسول الله. قال: «لا تَقُلْ عليك السلام؛ فإن عليك السلام تحيَّة المَوْتَى».
The meaning of the Hadīth: A man went to the Prophet (may Allah's peace and blessings be upon him) and greeted him saying: "Upon you be peace, O Messenger of Allah." So the Prophet forbade him from greeting in that way. And because the Prophet disliked his greeting, he even did not reply to it and told him that this is the way to greet the dead (not the living). Then the Prophet taught him the proper way to greet as mentioned in another Hadīth: "Say peace be upon you".
The Prophet's statement that this was the greeting of the dead does not mean that this is what should be said when visiting the graves, because the way of greeting the dead has been reported from the Prophet while visiting the graves as: "Peace be upon you, O dwellers of the abode of the believers." Rather, he said that in reference to the way people used to greet the dead in the pre-Islamic era.
Download for free and never miss a prayer again