UK Prayer Times
Hajj & Umrah · · 7 min read ·World Aid Network Editorial Team

Masjid Quba: The First Mosque in Islam — History, Virtues & Visiting Guide

Masjid Quba was the very first mosque built in Islam — founded by the Prophet Muhammad ﷺ himself in 622 CE upon his arrival in Madinah. Praying two rak'ahs here earns the reward of one Umrah.

Masjid Quba (مسجد قباء) holds a unique and unrivalled distinction in Islamic history: it was the first mosque ever built in Islam. The Prophet Muhammad ﷺ laid its foundation stones with his own blessed hands in 622 CE (1 AH), upon his arrival in Madinah at the start of the Hijra — the migration from Makkah that marks the beginning of the Islamic calendar.

A mosque founded on piety from the first day is more worthy for you to stand in. In it are men who love to purify themselves, and Allah loves those who purify themselves.
— Surah at-Tawbah (9:108) — revealed about Masjid Quba

The founding of Masjid Quba

When the Prophet ﷺ and Abu Bakr (RA) completed their journey from Makkah during the Hijra in 622 CE, they arrived first in the village of Quba, about 5 kilometres south of the city centre of Madinah. The Prophet ﷺ stayed in Quba for approximately 14 days, and during this time he personally laid the foundation stones of the mosque. He carried stones alongside his Companions, reciting: 'Allahumma laa 'aysha illa 'aysh al-akhirah' (O Allah, there is no life except the life of the Hereafter).

The Prophet's first Friday prayer (Jumu'ah) was performed not at Quba but on the way to Madinah proper, in the valley of Banu Salim. When he reached Madinah, the Prophet ﷺ built Masjid an-Nabawi — but Masjid Quba retains the supreme honour of being the first mosque to rise in Islam, with the Prophet's own hands placing its stones.

The extraordinary virtue of praying at Masjid Quba

The Prophet ﷺ visited Masjid Quba regularly — narrations indicate he visited every Saturday, sometimes walking and sometimes riding. He stated a powerful virtue for those who pray there:

مَنْ تَطَهَّرَ فِي بَيْتِهِ ثُمَّ أَتَى مَسْجِدَ قُبَاءٍ فَصَلَّى فِيهِ صَلَاةً، كَانَ لَهُ كَأَجْرِ عُمْرَةٍ

Man tatahhara fi baytihi thumma ata masjida Quba'a fasalla fihi salatan, kana lahu ka-ajri 'Umratin.

Whoever purifies himself in his home and then comes to Masjid Quba and prays in it, he will have the reward equal to that of Umrah.

(Sunan Ibn Majah 1412, Sahih al-Bukhari 1191 — narrated by Sahl ibn Hunayf (RA))

This makes Masjid Quba one of the most rewarding short journeys a Muslim can make. Two rak'ahs of prayer in Quba — after performing wudu at home — earns the reward of a full Umrah. Islamic scholars highlight that this reward is available every time one visits, not just once.

The Qur'anic verse revealed about Masjid Quba

Allah honoured Masjid Quba by name in the Qur'an (Surah at-Tawbah 9:108): 'A mosque founded on piety from the first day is more worthy for you to stand in.' The verse praises those who pray there for their love of purification — referring specifically to the Ansar (Helpers) of Madinah who would perform istinja (washing after relieving themselves) using water, rather than stones alone, a practice Allah praised as a sign of their striving for purity.

Location and how to visit Masjid Quba today

Masjid Quba is located approximately 5 kilometres south-west of Masjid an-Nabawi in Madinah. Today it stands as a large, modern white mosque with distinctive domed roofs and minarets, expanded and rebuilt by the Saudi government. It can accommodate around 20,000 worshippers. Free shuttle buses run regularly between Masjid an-Nabawi and Masjid Quba for visitors and pilgrims.

Most Hajj and Umrah packages include a ziyarah (visit) to Masjid Quba as part of the Madinah itinerary. Pilgrims are strongly encouraged to pray at least two rak'ahs there to earn the Umrah reward — this is one of the most beloved visits in all of Madinah.

Other sacred sites near Masjid Quba

Frequently asked questions about Masjid Quba

Which is the first mosque in Islam?

Masjid Quba is the first mosque built in Islam. It was founded by the Prophet Muhammad ﷺ in 622 CE (1 AH) upon his arrival in Madinah during the Hijra. The Prophet personally laid its foundation stones.

What is the reward for praying 2 rak'ahs in Masjid Quba?

The Prophet ﷺ said that whoever purifies themselves at home and then prays at Masjid Quba will receive the reward equal to performing one Umrah (Sunan Ibn Majah 1412, Sahih al-Bukhari 1191). This reward applies every time one visits, making regular visits while in Madinah highly recommended.

Did the Prophet ﷺ visit Masjid Quba regularly?

Yes. Ibn Umar (RA) narrated that the Prophet ﷺ would visit Masjid Quba every Saturday — sometimes on foot and sometimes riding — and pray two rak'ahs there (Sahih al-Bukhari 1193). Ibn Umar followed this practice throughout his life.

Is Masjid Quba in Makkah or Madinah?

Masjid Quba is in Madinah (also spelled Medina), approximately 5 kilometres south-west of Masjid an-Nabawi (the Prophet's Mosque). It is not in Makkah. Both Makkah and Madinah are in the Hejaz region of Saudi Arabia.

Support this free service

This site is a free sadaqah service from World Aid Network — no ads, no fees. If it helped you, please consider a small donation.

❤️ Donate

More from the Knowledge Hub