The Messenger of Allah ﷺ forbade continuous fasting without breaking it between days.A man from the Muslims said to him, "But you yourself fast continuously, Messenger of Allah."He replied, "Which of you is like me? I spend the night with my Lord feeding me and giving me drink."When they refused to stop fasting continuously, he fasted with them for one day, then another day, then they sighted the crescent moon. He said, "Had it been delayed, I would have continued with you longer," as a rebuke to them for refusing to stop.
نهي رسول الله ﷺ عن الوصال في الصوم. فقال له رجل من المسلمين: إنك تواصل يا رسول الله؟ قال: وأيكم مثلي، إني أبيت يطعمني ربي ويسقين. فلما أبوا أن ينتهوا عن الوصال، واصل بهم يوما، ثم يوما، ثم رأوا الهلال، فقال: لو تأخر لزدتكمكالتنكيل لهم حين أبوا أن ينتهوا.
Bukhari narrated it in the Book of Fasting (1965), and Muslim in the Book of Fasting (1103), both from the hadith of Zuhri, who said, Abu Salama bin Abdul-Rahman told me that Abu Hurairah said (then he related the hadith). Their wording is the same. They both also recorded it, Bukhari (1966) and Muslim (1103:58), through two different routes, from Abu Hurairah, "So take on only as much work as you can bear."