All perfect praise be to Allaah, the Lord of the worlds. I testify that there is none worthy of worship except Allaah and that Muhammad is His slave and Messenger.
If a person owes a vowed fast and is also required to make up for days that he missed in Ramadan, it is better for him to start making up for the days that he missed in Ramadan and then do the vowed fasting, provided that there is sufficient time for both. In other words, this is applicable as long as he will not exceed the restricted time for fulfilling both. In fact, Hanbali scholars maintain that it is obligatory to make up for the days missed in Ramadan before observing vowed fasting.
In his book Al-Mughni, Ibn Qudamah said:
If a person is required to make up for missed Ramadan fasts or expiatory fasts, then he must give such types of fasting priority over vowed fasting. This is because making up for missed fasts and observing expiatory fasts are imposed upon the person by the sharia whereas vowed fasting is imposed by the vowing person upon himself. Consequently, that which is imposed by the sharia must take priority over that which is imposed by the person upon himself. This is like the case where obligatory Hajj is to be given precedence over a vowed Hajj.
In his book Al-Insaaf, Al-Mardaawi says:
If a Muslim is required to fulfill an obligation imposed by the sharia as well as a vow, then he should start with the obligation imposed by the sharia provided that he will not miss the vowed duty, in which case he may start with it. Also, if a vowed fast is not restricted to a specific time or event, then the Muslim should start with making up for the days that he missed in Ramadan.
When the observance of missed days of fasting conflicts with the observance of a vowed fast, then the fasting of the missed days takes priority. For example, if a person has to make up for ten days that he missed in Ramadan and he also vowed to fast ten days in Sha‘baan (the month before Ramadan), and only ten days remain ahead of Ramadan, then he must proceed to make up for the ten days that he missed from last Ramadan since that is the only chance for him to make up for the missed days before the next Ramadan starts. In his book MataalibUli An-Nuha, Ar-Ruhaybaani says, “The aforementioned view of the Hanbali scholars implies that when there is not enough time to observe both fasts within their proper time limit, then it is obligatory to start with making up for the missed fasts of Ramadan and then follow it with observing vowed fasts.”
Allaah Knows best.