Narrated Abu Huraira (radiallaahu `anhu):
The Prophet (sallallaahu `alayhi wasallam) said, “If somebody eats or drinks forgetfully then he should complete his fast, for what he has eaten or drunk, has been given to him by Allah.”
Narrated ‘Amir bin Rabi’a (radiallaahu `anhu), “I saw the Prophet (sallallaahu `alayhi wasallam) cleaning his teeth with Siwak while he was fasting so many times as I can’t count.”
And narrated Abu Huraira (radiallaahu `anhu), “The Prophet (sallallaahu `alayhi wasallam) said, ‘But for my fear that it would be hard for my followers, I would have ordered them to clean their teeth with Siwak on every performance of ablution.”
The same is narrated by Jabir (radiallaahu `anhu) and Zaid bin Khalid (radiallaahu `anhu) from the Prophet who did not differentiate between a fasting and a non-fasting person in this respect (using Siwak).
Aisha (radiallaahu `anhaa) said, “The Prophet (sallallaahu `alayhi wasallam) said, “It (i.e. Siwak) is a purification for the mouth and it is a way of seeking Allah’s pleasures.” Ata’ and Qatada said, “There is no harm in swallowing the resultant saliva.”
I forgot that I was fasting and ate..
“but He will call you to account for that which your hearts have earned” [al-Baqarah 2:225]
Forgetfulness is not something which is earned by the heart.
This hadeeth tells of the kindness of Allaah to His slaves and how He makes things easier for them and alleviates hardship.
Whoever forgets that he is fasting and breaks the fast, his fast is still valid, and he should complete his fast, and he does not have to make it up or offer any expiation. The general meaning of the hadeeth covers both obligatory and naafil fasts; there is no difference between the two.
An interesting story was narrated by ‘Abd al-Razzaaq from ‘Amr ibn Dinar: that a person came to Abu Hurayrah and said: “I started fasting in the morning then I forgot and ate.” He said, “It does not matter.” He said: “Then I entered upon someone and by mistake I ate and drank.” He said, “It does not matter, Allaah has fed you and given you to drink.” Then he said: “I entered upon another person and forgot, and ate.” Abu Hurayrah said: “You are a person who is not used to fasting.”.
Siwaak and/or Toothpaste? Let’s solve the matter!
It is permissible for a fasting person to use miswaak and toothpaste whilst fasting, so long as he is careful not to swallow anything. In fact using the miswaak is Sunnah when fasting and otherwise.
It is permissible to swallow the saliva after using the siwaak, but if anything comes out of the siwaak in the mouth, you should spit it out and then swallow the saliva, just as the fasting person is allowed to do wudoo’, then he should spit out the water from his mouth and then swallow his saliva. He does not have to dry his mouth completely from the water used for rinsing.
Shaykh Ibn Baaz (may Allaah have mercy on him) was asked: What is the ruling on using toothpaste when fasting?
Cleaning the teeth with toothpaste does not break the fast as is the case with the miswaak. But one should be careful to avoid letting any of it reach his throat, but if that happens accidentally then he does not have to make up the fast.
End quote from Majmoo’ Fataawa al-Shaykh Ibn Baaz (15/260).