The Prophet's Guidance on Greeting When Entering a Gathering — Handshaking and Salam
The questioner asks about the guidance of the Prophet ﷺ — namely: when a person enters a gathering, does he shake hands with everyone? Nothing is established from the Prophet ﷺ regarding this. What is established from the Prophet ﷺ is the salam [greeting], and the salam is given to all.
Some people shake hands with every single person and say to each one: "Al-salam 'alaykum. Al-salam 'alaykum." So he gives salam to each individual along with the handshake. And giving salam to every person individually — even though he has already given salam to all — has no basis. This is to be discouraged.
As for the handshake — it may be from customs ('adat) rather than acts of worship ('ibadat), with the intent behind it being to bring hearts together, remove ill feelings, and dispel grudges. Such a practice brings about affection. But does this replace the verbal salam? If he gives salam to all once, that suffices. And if he shakes hands, he says: "How are you?" — asks after his wellbeing and makes du'a for him — and so on.
What appears is that the handshake is permissible, because the intent behind it is not worship — rather it is a custom for bringing hearts together. As for the hadith: "There are no two Muslims who meet and shake hands except that their sins fall away as leaves fall from a tree" — this hadith has some discussion about its chain of narration, and some scholars have graded it as hasan by the totality of its chains. It is possible to cite it as evidence for this matter — in the sense that he has already met and greeted them, and then at that point shakes their hands. But we do not say that this is the Sunnah — we say this is from the category of customs and traditions that do not contradict the Shari'ah.
