Anas bin Malik reported,

The Prophet ﷺ continued fasting through the night without breaking it at the end of the month, and some of the people did the same. When this reached the Prophet ﷺ, he said, "If the month were extended for me, I would continue fasting in such a way that those who go to extremes would abandon their excess. I am not like you. I spend the night with my Lord feeding me and giving me drink."

Azami 14643

Sahih

عن أنس قال

واصل النبي ﷺ آخر الشهر، وواصل أناس من الناس، فبلغ النبي ﷺ فقال: لو مد بي الشهر لواصلت وصالا يدع المتعمقون تعمقهم، إني لست مثلكم، إني أظل يطعمني ربي ويسقين.

الأعظمي 14643صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Superior moral conduct
Chapter
Etiquette of speech, words, and correspondence
Section
What is permissible to say regarding "if"
Numbering
Jami al-Kamil 14643 (2nd edition)
Azami 14643