If anyone forgets that he is fasting and eats or drinks he should complete his fast, for…

Sahih Muslim Book 13 Hadith 222

Sahih Muslim #1155

The Book of Fasting 13:222

Abu Huraira reported Allah's Messenger (ﷺ) as saying:

If anyone forgets that he is fasting and eats or drinks he should complete his fast, for it is only Allah Who has fed him and given him drink.

Chapter: The one who eats, drinks, or has intercourse by mistake does not break his fast

Grade: Sahih