Is a voluntary fast invalidated if it happens to coincide with Ramadan?
General Chapter
Al-Mughni
Book of Fasting
Primary text
If one fasts voluntarily and that day happens to be a day of Ramadan, it does not count for Ramadan. This is the explicit position of Ahmad, and it is the view of al-Shafi'i. This ruling depends on the requirement that the intention (Niyyah) for Ramadan must be specified.
Supporting text
The proponents of the opinion of Abu Hanifa hold that it does count, based on the issue of specifying the intention for Ramadan.