Ash-Shaykh Muhammad bin Saalih al-Uthaymeen rahimahullah, said,
“… If the person were to wake up after Fajr not have eaten anything, then decided to fast at noontime upon the intention that day is one of the six days of Shawāl [for him], as a result he fasted five days after that day. In this case he would have fasted five days and a half. Similarly, if he were to begin his intention after a quarter of the day had already passed, then he would have fasted five days and three quarters of a day [i.e a portion of the day] since actions are based upon the intentions. The Hadith states,
‘Whoever fasts Ramadan then follows it with six days of Shawwāl…’.
Therefore, we say to this brother you haven’t attained the reward for fasting the six days of Shawwāl being you didn’t fast six days, the same being said for the day of Arafah. As for if it was an unrestricted voluntary fast [i.e a regular voluntary fast], then it will be valid to do so and the reward starts from the timing the person begins his intention”. End. [Questions from Liqaa al-Baab al-Maftooh]
If it is a regular voluntary fast that is not restricted to a specific occasion, then he could make his intention whenever he wishes as long as he hasn’t done anything prior that would break his fast.
Ash-Shaykh Bin Baz rahimahullah, was asked the following,
“Concerning the voluntary fast, could the person initiate his intention whenever he wishes?”
“Yes, whenever he wishes as long as he has not done anything prior that would break his fast. He didn’t eat anything for example nor did do anything that would break his fast.” End.
Translated by AbuFajr AbdulFattaah Bin Uthman