Sayyiduna Abu Sa'id Khudri (may Allah be pleased with him) narrates that the Prophet (peace and blessings of Allah be upon him) said: "Whoever fasts in Ramadan, safeguards its limits, and protects what should be protected, then his past sins are forgiven."
Hadith Referenceصحیح ابن حبان / كتاب الصوم / 3433
Hadith Gradingفضيلة الشيخ الإمام محمد ناصر الدين الألبانيضعيف - «الضعيفة» (5083)، «تمام المِنَّة» / الصيام.فضيلة الشيخ العلّامة شُعيب الأرناؤوطإسناده ضعيف