Language:
كتاب الحدود
86  
Limits and Punishments set by Allah (Hudood)
(20)
Chapter: The sin of illegal sexual intercourse
(20)
باب إِثْمِ الزُّنَاةِ
Sahih al-Bukhari 6810

Narrated Abu Huraira:

The Prophet (ﷺ) said, "The one who commits an illegal sexual intercourse is not a believer at the time of committing illegal sexual intercourse and a thief is not a believer at the time of committing theft and a drinker of alcoholic drink is not a believer at the time of drinking. Yet, (the gate of) repentance is open thereafter."

حَدَّثَنَا آدَمُ، حَدَّثَنَا شُعْبَةُ، عَنِ الأَعْمَشِ، عَنْ ذَكْوَانَ، عَنْ أَبِي هُرَيْرَةَ، قَالَ قَالَ النَّبِيُّ صلى الله عليه وسلم ‏ "‏ لاَ يَزْنِي الزَّانِي حِينَ يَزْنِي وَهْوَ مُؤْمِنٌ، وَلاَ يَسْرِقُ حِينَ يَسْرِقُ وَهْوَ مُؤْمِنٌ، وَلاَ يَشْرَبُ حِينَ يَشْرَبُهَا وَهْوَ مُؤْمِنٌ، وَالتَّوْبَةُ مَعْرُوضَةٌ بَعْدُ ‏"‏‏.‏
Reference : Sahih al-Bukhari 6810
In-book reference : Book 86, Hadith 39
USC-MSA web (English) reference : Vol. 8, Book 82, Hadith 801
  (deprecated numbering scheme)