Sayyiduna Khuzaymah bin Thabit (may Allah be pleased with him) reports this saying of the Prophet (peace and blessings be upon him): "Any servant who commits something that Allah Almighty has forbidden, and then the hadd punishment is carried out on him, that punishment removes that sin from him."
Hadith Referenceمجمع الزوائد ومنبع الفوائد / كتاب الحدود والديات / 10595
Hadith Gradingمحدثین:إسنادہ صحیح۔
Hadith Takhrij«الخرجه الطبراني فى المعجم الكبير (3731) اخرجه احمد فى المسند (214/5) ، أخرجه مسند أحمد برقم: 21369، وأخرجه المستدرك على الصحيحين برقم: 8228، وأخرجه المعجم الكبير للطبراني برقم: 3731، 3732»