Anas bin Malik reported,

Two men sneezed in the presence of the Prophet ﷺ. He invoked a blessing for one of them but not the other.The one for whom he had not invoked a blessing said, "So-and-so sneezed and you blessed him, but I sneezed and you did not bless me."The Prophet ﷺ replied, "This man praised Allah, but you did not praise Allah."

Azami 14141

Sahih

عن أنس بن مالك، قال

عطس عند النبي ﷺ رجلان، فشمت أحدهما ولم يشمت الآخر، فقال الذي لم يشمته: عطس فلان، فشمته، وعطست أنا فلم تشمتني، قال: إن هذا حمد الله، وإنك لم تحمد الله.

الأعظمي 14141صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Superior moral conduct
Chapter
Characteristics of Muslims, and their rights upon one another
Section
Not responding to the one who sneezes if he does not praise Allah
Numbering
Jami al-Kamil 14141 (2nd edition)
Azami 14141