Sahih al-Bukhari, Hadith 1915

Narrated Al-Bara: It was the custom among the companions of Muhammad that if any of them was fasting and the food was presented (for breaking his fast), but he slept before eating, he would not eat that night and the following day till sunset. Qais bin Sirma-al-Ansari was fasting and came to his wife at the time of Iftar (breaking one's fast) and asked her whether she had anything to eat. She replied, "No, but I would go and bring some for you." He used to do hard work during the day, so he was overwhelmed by sleep and slept. When his wife came and saw him, she said, "Disappointment for you." When it was midday on the following day, he fainted and the Prophet was informed about the whole matter and the following verses were revealed: "You are permitted To go to your wives (for sexual relation) At the night of fasting." So, they were overjoyed by it. And then Allah also revealed: "And eat and drink Until the white thread Of dawn appears to you Distinct from the black thread (of the night)." (2.187)

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

sunnah.com