Anas bin Malik reported,

Anas, who used to follow the Prophet ﷺ, serve him, and accompany him, reported that Abu Bakr was leading the people in prayer during the illness in which the Prophet ﷺ passed away. When Monday came and they were standing in rows for the prayer, the Prophet ﷺ drew aside the curtain of the chamber and looked at us while standing, his face like a page of the Quran. Then he smiled and laughed, and we were nearly distracted out of joy at seeing the Prophet ﷺ. Abu Bakr stepped back on his heels to join the row, thinking that the Prophet ﷺ was coming out for the prayer. But the Prophet ﷺ gestured to us to complete our prayer, then he let the curtain fall. He passed away that very day.

Azami 9334

Sahih

عن أنس بن مالك الأنصاري

- وكان تبع النبي ﷺ وخدمه وصحبه- أن أبا بكر كان يصلي لهم في وجع النبي ﷺ الذي توفي فيه، حتى إذا كان يوم الاثنين وهم صفوف في الصلاة فكشف النبي ﷺ ستر الحجرة ينظر إلينا وهو قائم كأن وجهه ورقة مصحف، ثم تبسم يضحك، فهممنا أن نفتتن من الفرح برؤية النبي ﷺ، فنكص أبو بكر على عقبيه ليصل الصف، وظن أن النبي ﷺ خارج إلى الصلاة، فأشار إلينا النبي ﷺ: أن أتموا صلاتكم، وأرخى الستر، فتوفي من يومه.

الأعظمي 9334صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Biography of the Prophet ﷺ
Chapter
Nearness of his death, his foretelling of it, his passing, and his burial
Section
Prophet ﷺ smiling during his final illness
Numbering
Jami al-Kamil 9334 (2nd edition)
Azami 9334