Hadith 1039

عَنِ ابْنِ عُمَرَ قَالَ: قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: «لَا يَتَحَرَّى أَحَدُكُمْ فَيُصَلِّيَ عِنْدَ طُلُوعِ الشَّمْسِ وَلَا عِنْدَ غُرُوبِهَا» وَفِي رِوَايَةٍ قَالَ: «إِذَا طَلَعَ حَاجِبُ الشَّمْسِ فدعوا الصَّلَاة حَتَّى تبرز. فَإِذا غَابَ حَاجِبُ الشَّمْسِ فَدَعُوا الصَّلَاةَ حَتَّى تَغِيبَ وَلَا تَحَيَّنُوا بِصَلَاتِكُمْ طُلُوعَ الشَّمْسِ وَلَا غُرُوبَهَا فَإِنَّهَا تطلع بَين قَرْني الشَّيْطَان»
Ibn ‘Umar reported God’s Messenger as saying, “None of you must choose for himself and pray at the rising or setting of the sun.” In a version he said, “When the rim of the sun rises leave off prayer till it comes right up, when the rim of the sun goes below the horizon leave off prayer till it has set, and do not make the rising or setting of the sun your time of prayer, for it rises between the horns of the devil.” (Bukhari and Muslim.)
Hadith Reference Mishkat al-Masabih / The Book of Prayer / Hadith: 1039
Hadith Grading الألبانی: مُتَّفق عَلَيْهِ  |  زبیر علی زئی: متفق عليه
Hadith Takhrij ´تحقيق و تخريج: محدث العصر حافظ زبير على زئي رحمه الله` «متفق عليه، رواه البخاري (583، 3272) و مسلم (291/ 829)»