The Messenger of Allah ﷺ said, "When you see a man frequenting the masjid regularly, bear witness that he has faith." Allah said, "The masjids of Allah are only maintained by those who believe in Allah and the Last Day" [Tawbah 9:18].
وبهذا الإسناد أن رسول الله ﷺ قال إذا رأيتم الرجل يعتاد المسجد فاشهدوا عليه بالإيمان قال الله عز وجل {إنما يعمر مساجد الله من آمن بالله واليوم الآخر}