The sun was eclipsed during the lifetime of the Prophet ﷺ, so he went out to the mosque and the people lined up in rows behind him. He pronounced the takbir and recited a long recitation, then pronounced the takbir and made a long bowing. Then he said, "Allah hears whoever praises Him," and stood up without prostrating, and recited another long recitation, somewhat shorter than the first. Then he pronounced the takbir and made another long bowing, somewhat shorter than the first. Then he said, "Allah hears whoever praises Him. Our Lord, to You belongs all praise," and then prostrated. He did the same in the second rakah, completing four bowings in two rakahs with four prostrations. The sun became clear before he finished.Then he stood and praised Allah as He deserves, then said, "These two are signs among the signs of Allah. They are not eclipsed for anyone's death or life, so when you see them, hasten to prayer."
خسفت الشمس في حياة النبي ﷺ فخرج إلى المسجد فصف الناس وراءه، فكبر فاقترأ رسول الله ﷺ قراءة طويلة، ثم كبر فركع ركوعا طويلا. ثم قال: سمع الله لمن حمده فقام ولم يسجد وقرأ قراءة طويلة، أدنى من القراءة هي الأولى، ثم كبر وركع ركوعا طويلا، وهو أدنى من الركوع الأول، ثم قال: سمع الله لمن حمده ربنا ولك الحمد ثم سجد، ثم قال في الركعة الآخرة مثل ذلك، فاستكمل أربع ركعات في أربع سجدات، وانجلت الشمس قبل أن ينصرف. ثم قام فأثنى على الله بما هو أهله ثم قال: هما آيتان من آيات الله لا يخسفان لموت أحد ولا لحياته، فإذا رأيتموهما فانزعوا إلى الصلاة.
Bukhari narrated it in the Book of the Eclipse (1046) and Muslim in the Book of the Eclipse (3/901), both of them through Ibn Shihab, who said, Urwa narrated to me, from Ayesha, and I mentioned it, and the wording given is Bukhari's. This hadith from her was already mentioned as narrated by Malik, and from him the two Shaykhs (Bukhari and Muslim) narrated it, and it contains an explicit mention of the sermon. This explicit mention also occurs in Bukhari's narration (1047) from his teacher Saeed bin Afir, from Layth.