Q. Can a Musalla which has flats or shops above it be changed to a Masjid?
A. It is not permissible to build flats, houses, shops, etc. above or below an existing Masjid.
However, it is permissible to build flats, houses, shops, etc. above or below a Masjid if the areas of the flats, houses and shops are excluded from the Masjid area prior to declaring it a Masjid. It cannot be done after it has already been declared a Masjid.
Most importantly, in doing so, the flats, houses, shops etc. cannot be in the ownership of any person. It must be solely for the benefit, purposes and objectives (Maslaha) of the Masjid or made an endowment (Waqf) to the Masjid.
Therefore, if the benefit, income or profit generated from the flats, houses, shops etc. are used solely for the benefit, purposes and objectives of the Masjid or it is a Waqf of the Masjid, it would be permissible to build them above or below the Masjid.
Thus, a Musalla in a building which has flats or shops above or below it may be declared a Masjid if the above conditions are met. (Shaami 4/358 – Bahrur-Raaiq 5/271 – Kitaabul Fataawa 4/233)
Allah Ta’ala Knows Best
Mufti Ismaeel Bassa
themufti.com