Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
bayhaqi:16914Abū Zakariyyā b. Abū Isḥāq > Abū al-Ḥasan Aḥmad b. Muḥammad b. ʿUbdūs > ʿUthmān b. Saʿīd > ʿAbdullāh b. Ṣāliḥ > Muʿāwiyah b. Ṣāliḥ > ʿAlī b. Abū Ṭalḥah

[Machine] In his statement "{And those who commit immorality from your women}" [Surah An-Nisa 15], he said that when a woman committed adultery, she would be confined to the house until her death. And in his statement "{And the two who commit it [i.e., unlawful sexual intercourse] among you}" [Surah An-Nisa 16], he said that when a man committed adultery, he would be dishonored and struck with sandals. Then Allah revealed after this "{The [unmarried] woman or [unmarried] man found guilty of sexual intercourse – lash each one of them with a hundred lashes}" So if they were previously married, they would be stoned according to the Sunnah of the Messenger of Allah ﷺ. And this is their prescribed punishment set by Allah for them.  

البيهقي:١٦٩١٤أَخْبَرَنَا أَبُو زَكَرِيَّا بْنُ أَبِي إِسْحَاقَ أنبأ أَبُو الْحَسَنِ أَحْمَدُ بْنُ مُحَمَّدِ بْنُ عُبْدُوسٍ ثنا عُثْمَانُ بْنُ سَعِيدٍ ثنا عَبْدُ اللهِ بْنُ صَالِحٍ عَنْ مُعَاوِيَةَ بْنِ صَالِحٍ عَنْ عَلِيِّ بْنِ أَبِي طَلْحَةَ عَنِ ابْنِ عَبَّاسٍ

فِي قَوْلِهِ {وَاللَّاتِي يَأْتِينَ الْفَاحِشَةَ مِنْ نِسَائِكُمْ} [النساء 15] الْآيَةَ قَالَ كَانَتِ الْمَرْأَةُ إِذَا زَنَتْ حُبِسَتْ فِي الْبَيْتِ حَتَّى تَمُوتَ وَفِي قَوْلِهِ {وَاللَّذَانِ يَأْتِيَانِهَا مِنْكُمْ فَآذُوهُمَا} [النساء 16] قَالَ كَانَ الرَّجُلُ إِذَا زَنَى أُوذِيَ بِالتَّعْيِيرِ وَضَرْبِ النِّعَالِ فَأَنْزَلَ اللهُ ﷻ بَعْدَ هَذَا {الزَّانِيَةُ وَالزَّانِي فَاجْلِدُوا كُلَّ وَاحِدٍ مِنْهُمَا مِائَةَ جَلْدَةٍ} فَإِنْ كَانَا مُحْصِنَيْنِ رُجِمَا فِي سُنَّةِ رَسُولِ اللهِ ﷺ وَهَذَا سَبِيلُهُمَا الَّذِي جَعَلَ اللهُ لَهُمَا  


See similar narrations below:

Collected by Abū Dāwūd
abudawud:4413Aḥmad b. Muḥammad b. Thābit al-Marwazī > ʿAlī b. al-Ḥusayn from his father > Yazīd al-Naḥwī > ʿIkrimah > Ibn ʿAbbās

The Qur’anic verse goes: “If any of your woman are guilty of lewdness, take the evidence of four (reliable) witnesses from amongst you against them, and if they testify, Confine them to houses until death do chain them or Allah ordains for them some (other) way. Allah then mentioned man after woman and combined them in another verse : “If two men among you are guilty of lewdness, punish them both. If they repent and amend, leave them alone. This command was abrogated by the verse relating to flogging : “The woman and the man guilty of adultery or fornication – flog each of them with one hundred stripes.  

أبو داود:٤٤١٣حَدَّثَنَا أَحْمَدُ بْنُ مُحَمَّدِ بْنِ ثَابِتٍ الْمَرْوَزِيُّ حَدَّثَنِي عَلِيُّ بْنُ الْحُسَيْنِ عَنْ أَبِيهِ عَنْ يَزِيدَ النَّحْوِيِّ عَنْ عِكْرِمَةَ عَنِ ابْنِ عَبَّاسٍ قَالَ

{ وَاللاَّتِي يَأْتِينَ الْفَاحِشَةَ مِنْ نِسَائِكُمْ فَاسْتَشْهِدُوا عَلَيْهِنَّ أَرْبَعَةً مِنْكُمْ فَإِنْ شَهِدُوا فَأَمْسِكُوهُنَّ فِي الْبُيُوتِ حَتَّى يَتَوَفَّاهُنَّ الْمَوْتُ أَوْ يَجْعَلَ اللَّهُ لَهُنَّ سَبِيلاً } وَذَكَرَ الرَّجُلَ بَعْدَ الْمَرْأَةِ ثُمَّ جَمَعَهُمَا فَقَالَ { وَاللَّذَانِ يَأْتِيَانِهَا مِنْكُمْ فَآذُوهُمَا فَإِنْ تَابَا وَأَصْلَحَا فَأَعْرِضُوا عَنْهُمَا } فَنَسَخَ ذَلِكَ بِآيَةِ الْجَلْدِ فَقَالَ { الزَّانِيَةُ وَالزَّانِي فَاجْلِدُوا كُلَّ وَاحِدٍ مِنْهُمَا مِائَةَ جَلْدَةٍ }