It is narrated from Sayyiduna Tariq bin Abdullah al-Muharibi (may Allah be pleased with him), a Companion of the Prophet (peace and blessings be upon him), that the Messenger of Allah (peace and blessings be upon him) said to me: "When you pray, do not spit in front of you or to your right; rather spit to your left, provided it is empty, or else under your foot."
Besides the chains we have mentioned, a group also narrated it from Mansur (may Allah have mercy on him): Sulayman bin Mihran, Abu al-Ahwas, Qays bin al-Rabi', Mufaddal bin Muhalhil, Ja'far bin al-Harith and Ubaydah bin Humayd (may Allah have mercy on them).
Imam Ahmad (may Allah have mercy on him) narrated it from Yahya bin Sa'id (may Allah have mercy on him), and at its end is: "And he (peace and blessings be upon him) rubbed it under his feet."
And (he narrated it) through Muhammad bin Ja'far from Shu'bah (may Allah have mercy on him), and it has this addition: "Then rub it."
And (he narrated it) through Ubaydah bin Humayd from Mansur (may Allah have mercy on him), and it also has: "Then rub it."
Imam Abu Dawud (may Allah have mercy on him) narrated it through Hannad from Abu al-Ahwas, from Mansur (may Allah have mercy on him), with the like of it.
Imam al-Tirmidhi (may Allah have mercy on him) narrated it through Bundar and said: "This hadith is hasan sahih."
Imam al-Nasa'i (may Allah have mercy on him) narrated it through Ubaydullah bin Sa'id from Yahya bin Sa'id (may Allah have mercy on him), with the like of it.
Imam Ibn Majah (may Allah have mercy on him) narrated it through Abu Bakr bin Abi Shaybah from Waki', from Sufyan (may Allah have mercy on him), with the like of it.
It has a supporting narration in the two Sahihs through Shu'bah, from Qatadah, from Anas bin Malik (may Allah be pleased with him), who said that the Messenger of Allah (peace and blessings be upon him) said: "When one of you is in prayer, he is speaking intimately with his Lord, so let him not ever spit in front of him or to his right, but rather to his left, under his foot."
And through Humayd bin Abd al-Rahman (may Allah have mercy on him), it is narrated from Sayyiduna Abu Sa'id al-Khudri (may Allah be pleased with him) that the Prophet (peace and blessings be upon him) saw some phlegm on the qiblah side of the mosque, so he scraped it off with a pebble; then he (peace and blessings be upon him) forbade a man to spit to his right or in front of him, but rather he should spit to his left or under his left foot.
Related hadith on this topic