The World Federation One Stop Fiqh

Ruling 1543

If it is obligatory on a person to keep an assigned [i.e. time-specific] fast other than the fast of the month of Ramadan – for example, he had made a vow that he would fast on a particular day – in the event that he intentionally does not make the intention to keep that fast until the time of ṣubḥ prayers, his fast is invalid. However, if he does not know that it is obligatory on him to fast on that day, or he forgets and remembers before ẓuhr, in the event that he has not done anything that invalidates a fast and consequently makes the intention to fast, his fast will be valid. However, if he remembers after ẓuhr, he must exercise the obligatory precautionary measure that was mentioned concerning the fast of Ramadan [in Ruling 1533, which stated that he must abstain for the rest of the day from the eight things that invalidate a fast with a general intention of attaining proximity to Allah, and that he must also keep a qaḍāʾ fast for it].