Narrated Anas: The people of Makkah asked the Prophet (ﷺ) for a sign, so the moon was cleft asunder in Makkah two times (meaning two parts), so the following was revealed: 'The Hour has drawn near, and the moon has been cleft asunder, up to his saying: 'Magic, Mustamir (54:1 & 2)' meaning 'Going away.'

حَدَّثَنَا عَبْدُ بْنُ حُمَيْدٍ، حَدَّثَنَا عَبْدُ الرَّزَّاقِ، عَنْ مَعْمَرٍ، عَنْ قَتَادَةَ، عَنْ أَنَسٍ، قَالَ:‏‏‏‏ سَأَلَ أَهْلُ مَكَّةَ النَّبِيَّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ آيَةً فَانْشَقَّ الْقَمَرُ بِمَكَّةَ مَرَّتَيْنِ، ‏‏‏‏‏‏فَنَزَلَتْ:‏‏‏‏ اقْتَرَبَتِ السَّاعَةُ وَانْشَقَّ الْقَمَرُ إِلَى قَوْلِهِ سِحْرٌ مُسْتَمِرٌّ سورة القمر آية 1 ـ 2، ‏‏‏‏‏‏يَقُولُ:‏‏‏‏ ذَاهِبٌ . قَالَ أَبُو عِيسَى:‏‏‏‏ هَذَا حَدِيثٌ حَسَنٌ صَحِيحٌ.

Explanation
تفسير الحديث

This hadith narrates an episode from the life of the Prophet Muhammad (peace be upon him), where the people of Mecca asked him for a sign to prove his prophethood. In response, he gave them the miracle of the moon splitting into two halves. This event is referenced in the Qur'an in Surah Al-Qamar, where it states: "The Hour has drawn near, and the moon has split," indicating that the splitting of the moon was a sign of his prophethood. Reactions to this were mixed, with some describing the event as magic, reflecting their disbelief in the Prophet's miracle. This hadith highlights the Prophet's abilities and the significance of his miracles in his mission.

هذا الحديث يروي قصة من تاريخ النبي محمد صلى الله عليه وسلم، حيث سأل أهل مكة النبي عن آية تثبت نبوته. فأعطاهم معجزة وهي انشقاق القمر إلى قسمين. هذا الحدث تم الإشارة إليه في القرآن الكريم في سورة القمر، حيث تذكر الآيات: "اقْتَرَبَتِ السَّاعَةُ وَانْشَقَّ الْقَمَرُ"، مما يدل على أن انشقاق القمر كان علامة لنبوته. ردود الأفعال كانت مختلفة، حيث وصف بعضهم هذا الحدث بأنه سحر، وهذا يعبر عن عدم إيمانهم بمعجزة النبي. يجعل هذا الحديث من علامات قدرة النبي صلى الله عليه وسلم وأهمية معجزاته في دعوته.

Source: Jami' Al-Tirmidhi by Abu `Isa Muhammad at-Tirmidhi