Someone asked the Prophet ﷺ about the first mosque established for mankind. He replied, "The Sacred Mosque."The questioner then asked, "Which was next?"He said, "Bayt al-Maqdis."The questioner asked, "How long was the period between them?"He answered, "Forty years. And wherever the time of prayer overtakes you, pray, for that place is a mosque."
حدثنا محمد بن جعفر حدثنا شعبة عن سليمان قال سمعت إبراهيم التيمي يحدث عن أبيه
عن النبي ﷺ أنه سأله عن أول مسجد وضع للناس قال المسجد الحرام ثم بيت المقدس فسئل كم بينهما قال أربعون عاما وحيثما أدركتك الصلاة فصل فثم مسجد