Hadithcore
Sahih al-Bukhari, 1900
sahih

Narrated Ibn `Umar:

I heard Allah's Messenger (ﷺ) saying, "When you see the crescent (of the month of Ramadan), start fasting, and when you see the crescent (of the month of Shawwal), stop fasting; and if the sky is overcast (and you can't see it) then regard the month of Ramadan as of 30 days."

حَدَّثَنَا يَحْيَى بْنُ بُكَيْرٍ، قَالَ حَدَّثَنِي اللَّيْثُ، عَنْ عُقَيْلٍ، عَنِ ابْنِ شِهَابٍ، قَالَ أَخْبَرَنِي سَالِمٌ، أَنَّ ابْنَ عُمَرَ ـ رضى الله عنهما ـ قَالَ سَمِعْتُ رَسُولَ اللَّهِ صلى الله عليه وسلم يَقُولُ ‏

‏ إِذَا رَأَيْتُمُوهُ فَصُومُوا، وَإِذَا رَأَيْتُمُوهُ فَأَفْطِرُوا، فَإِنْ غُمَّ عَلَيْكُمْ فَاقْدُرُوا لَهُ ‏

‏‏.‏ وَقَالَ غَيْرُهُ عَنِ اللَّيْثِ حَدَّثَنِي عُقَيْلٌ وَيُونُسُ لِهِلاَلِ رَمَضَانَ‏.‏

References2 variants
In-Book Reference
Book 30, Hadith 10
USC-MSA web (English) reference
Vol. 3, Book 31, Hadith 124 (deprecated numbering scheme)
Sharh · explanationclick to expand
Allah, Exalted is He, decreed that the sighting of the new moon (crescent) should be used to determine the timings of the lunar months. The sighting of the crescent marks the end of a lunar month and the beginning of another. Based on that sighting, many religious obligations are determined, such as fasting and Hajj. In this hadeeth, the Prophet ﷺ underlined that Muslims must not observe fasting in the month of Ramadan except after sighting the new moon after the sunset of the twenty-ninth day of Sha‘baan, and also must not end their fasting (at the end of the month) except after sighting the crescent of the month of Shawwaal after sunset on the twenty-ninth day of Ramadan. If the sighting of the new moon is not possible because of clouds, or for any given reason, the month will be considered thirty days, because the maximum length of a lunar month is thirty days, and thus it is proved with certainty that the month has begun or ended. It is also deduced from the hadeeth that it is not allowable to rely on meansother than the sighting of the new moon to determine the beginning and end of lunar months, such as the astronomical calculation. .
Related hadiths12
Compare isnād across 12 related chains →