Fasting is obligatory on the:

  1. Muslim
  2. Bāligh (attained physical & cognitive maturity)
  3. Sane (cognitive maturity & the capacity to understand the obligation, its fulfilment and reward)
  4. Resident (not travelling or able to fast while in Travel)
  5. Able
  6. Free of valid Sharʿī excuse(s)

As regards those who do not fall in the above categories…

Disbeliever        

Fasting is not obligatory and there is no spiritual reward assigned for performing it.

Pre-pubert (minor)       

Not obligatory but recommended if able to sustain the fast.

Mentally incapacitated:

None of the Islamic pillars are obligatory on them with the exception zakāt (according to the majority view) being paid by those financially responsible for their estate.

Traveller            

Permitted to break the fast but is required to make up for it later.