💐 In The Name Of Allah The Most Gracious The Most Merciful
📜 Question: Does fasting a voluntary/Sunnah fast (like on Mondays, Thursdays, in Sha'baan and six days of Shawwaal) require a fixed niyyah/intention prior to its performance? Or is it possible for the Muslim to intend to fast a Sunnah fast any time of the day, if he or she did not eat nor drink anything after Salat Al-Fajr?
📝 Answer: There is no problem in this. It is not a condition to fix one's niyyah/intention when it comes to a voluntary/Sunnah fast. If the person woke up in the morning without eating and drinking anything, then he or she can make the niyyah/intention to fast a Sunnah fast, as it was mentioned in a Hadith in which the noble Messenger Muhammad SallAllahu 'alaihi wa sallam entered upon 'Aisha RadhiAllahu 'anha one day asking if there was anything to eat. When she said no, he SallAllahu 'alaihi wa sallam responded with, "in that case, I am fasting."
Therefore you can fast starting from any time of the day as long as you did not do anything beforehand which would invalidate a fast (such as eating, drinking, having intercourse with one's spouse in the morning etc.)
As for the obligatory fast in Ramadan, then it is mandatory to fix one's niyyah/intention before wanting to fast on a day in Ramadan, before the Adhan of the Fajr Salah. Yes.
~•~
📖 Abu Huraira RadhiAllahu 'anhu narrated: Allah's noble Messenger Muhammad SallAllahu 'alaihi wa sallam said, "The deeds are presented on Monday and Thursday. Thus, I love for my deeds to be presented while I am fasting."
Source: Sunan At-Tirmidhi 747
Grade: Sahih (Authentic) according to Al-Albani
📖 'Aisha RadhiAllahu 'anha narrated: The Messenger of Allah SallAllahu 'alaihi wa sallam said to me one day, “O Aisha, do you have anything to eat?” She said, “O Messenger of Allah, I have nothing.” The Prophet SallAllahu 'alaihi wa sallam said, “Then I am fasting.”
Source: Sahih Muslim 1154
Grade: Sahih (Authentic) according to Muslim
Al-Nawawi said, “In this is evidence for the view of the majority, that it is permissible to form an intention to voluntarily fast during the day before the setting of the sun.”
Source: Sharḥ Al-Nawawī ‘alá Sahih Muslim 1154
https://binbaz.org.sa/fatwas/12156/%D8%AD%D9%83%D9%85-%D8%AA%D8%A8%D9%8A%D9%8A%D8%AA-%D8%A7%D9%84%D9%86%D9%8A%D8%A9-%D9%81%D9%8A-%D8%B5%D9%8A%D8%A7%D9%85-%D8%A7%D9%84%D9%86%D8%A7%D9%81%D9%84%D8%A9