Abu Hurairah and Abu Saeed Khudri reported,

The Messenger of Allah ﷺ saw some phlegm on the wall of the mosque, so he picked up a pebble and scraped it off. Then he said, "When one of you needs to spit, he should not spit in front of his face, nor to his right. Let him spit to his left or beneath his left foot."

Bukhari 409

Sahih

حدثنا موسى بن إسماعيل قال أخبرنا إبراهيم بن سعد أخبرنا ابن شهاب عن حميد بن عبد الرحمن أن

أبا هريرة وأبا سعيد حدثاه

أن رسول الله ﷺ رأى نخامة في جدار المسجد فتناول حصاة فحكها فقال إذا تنخم أحدكم فلا يتنخمن قبل وجهه ولا عن يمينه وليبصق عن يساره أو تحت قدمه اليسرى

البخاري 409صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Prayer
Chapter
Scraping mucus from the masjid with pebbles
Numbering
Darussalam 409
Bukhari 409