He heard the Prophet ﷺ say, "There is no servant who prostrates to Allah a single prostration except that Allah records for him by it a good deed, erases by it a bad deed, and raises him by it one degree. So prostrate often."
أنه سمع النبي ﷺ يقول: ما من عبد يسجد لله سجدة إلا كتب الله له بها حسنة، ومحا عنه بها سيئة، ورفع له بها درجة، فأكثروا من السجود.
Ibn Majah (1424) reported it from Abbas bin Uthman Dimashqi, who said, "Walid bin Muslim narrated to us, from Khalid bin Yazid Marri, from Yunus bin Maysara bin Halabas, from Sanabihi, from Ubada bin Samit," and he mentioned it.Its isnad is sahih, and Walid bin Muslim was a mudallis, but he explicitly stated that he heard it directly, as recorded by Abu Naeem in al-Hilya (5/130), and the majority hold that his stating he heard it directly from his teacher is sufficient.