Al-Adab Al-Mufrad, Book 42, Hadith 991 (English)

Abu Hurayra said, "I heard the Messenger of Allah, may Allah bless him and grant him peace, say, 'The rights a Muslim has over another Muslim are six." He was asked, "What are they?" He replied, "When he meets him, he should greet him, When he gives him an invitation, he should accept. When he asks him for advice, he should give him good counsel. When he sneezes and praises Allah, he should wish him mercy. when he is ill, he should visit him. When he dies, he should accompany him."

حَدَّثَنَا إِسْمَاعِيلُ، قَالَ‏:‏ حَدَّثَنَا مَالِكٌ، عَنِ الْعَلاَءِ بْنِ عَبْدِ الرَّحْمَنِ، عَنْ أَبِيهِ، عَنْ أَبِي هُرَيْرَةَ، عَنِ النَّبِيِّ صلى الله عليه وسلم قَالَ‏:‏ حَقُّ الْمُسْلِمِ عَلَى الْمُسْلِمِ سِتٌّ، قِيلَ‏:‏ وَمَا هِيَ‏؟‏ قَالَ‏:‏ إِذَا لَقِيتُهُ فَسَلِّمْ عَلَيْهِ، وَإِذَا دَعَاكَ فَأَجِبْهُ، وَإِذَا اسْتَنْصَحَكَ فَانْصَحْ لَهُ، وَإِذَا عَطَسَ فَحَمِدَ اللَّهَ فَشَمِّتْهُ، وَإِذَا مَرِضَ فَعُدْهُ، وَإِذَا مَاتَ فَاصْحَبْهُ‏.‏

sunnah.com