Sunan an-Nasa'i 2205
It was narrated that Abu Hurairah said:"The Messenger of Allah said: 'Whoever fasts Ramadan out of faith and in the hope of reward, he will be forgiven his previous sins
أَخْبَرَنَا عَلِيُّ بْنُ الْمُنْذِرِ، قَالَ حَدَّثَنَا ابْنُ فُضَيْلٍ، قَالَ حَدَّثَنَا يَحْيَى بْنُ سَعِيدٍ، عَنْ أَبِي سَلَمَةَ، عَنْ أَبِي هُرَيْرَةَ، رضى الله عنه قَالَ قَالَ رَسُولُ اللَّهِ صلى الله عليه وسلم " مَنْ صَامَ رَمَضَانَ إِيمَانًا وَاحْتِسَابًا غُفِرَ لَهُ مَا تَقَدَّمَ مِنْ ذَنْبِهِ " .
Sahih — Abu GhuddahSahih — Al-AlbaniSahih Bukhari — Zubair Ali Zai