Aisha bint Abi Bakr (Companion) → [transmitted through the established chains of Sahih al-Bukhari and Sahih Muslim] → collected by Imam Yahya ibn Sharaf an-Nawawi in Riyad as-Salihin
Aisha, Umm al-Mu'minin, may Allah be pleased with her, reported that the Messenger of Allah, peace be upon him, said: 'An army will march to attack the Ka'bah, and when they reach a barren stretch of desert land, they will all be swallowed up by the earth, the first of them and the last of them.' She said: 'I asked, O Messenger of Allah, how will the first and the last of them be swallowed up when among them are their own tradespeople and others who are not truly part of their cause?' He said: 'They will all be swallowed up, the first and the last of them, and then they will be resurrected and judged according to their individual intentions.' [Agreed upon, this being al-Bukhari's wording]
Explanation
This hadith describes a striking end-times prophecy: an army will one day march against the Ka'bah with hostile intent, and when it reaches a particular open desert stretch, the earth will swallow the entire force, from its front ranks to its rear. Aisha's follow-up question captures a natural human concern for fairness: surely not every person in such a large force would share the same evil intention, since large armies inevitably include tradesmen, servants, and others swept along by circumstance rather than genuine hostile purpose toward the sacred House.
The Prophet's ﷺ answer resolves this tension elegantly: the physical punishment of being swallowed by the earth will indeed befall everyone present without exception, but the ultimate judgment and resurrection of each individual will be entirely according to their own private intention (niyyah), meaning the outwardly identical fate does not determine the person's actual standing before Allah.
This hadith therefore reinforces one of the most central themes running throughout Islamic ethics: actions and even shared circumstances are judged by Allah according to individual intention, not merely outward participation or appearance. Someone caught up in a catastrophe or a group action through no true intention of their own will be resurrected and held accountable strictly according to what was genuinely in their heart, even if their outward fate in this world was identical to those around them who bore real hostile intent.
When and why it was said
This hadith is widely understood by scholars to refer to a future eschatological event connected to the end of days, specifically an attack aimed at destroying the Ka'bah, Islam's most sacred site, which numerous other hadiths describe occurring near the establishment of the Dajjal or close to the Hour. Its placement as the second hadith in Imam an-Nawawi's opening chapter on sincerity, immediately after the famous hadith on intentions narrated by 'Umar ibn al-Khattab, reflects an editorial choice: An-Nawawi selected this narration specifically because it illustrates the intentions principle in its most dramatic, high-stakes form imaginable, applied to a scenario of collective divine punishment rather than an everyday individual action.
What the scholars said
Commentators on Sahih al-Bukhari and Sahih Muslim, where this hadith is jointly recorded, discuss extensively which specific army and historical moment this prophecy refers to, with many scholars connecting it to reports about an assault on the Ka'bah occurring near the end of times, though some early historical incidents, including certain attacks during the era of the Umayyads, have also been discussed by scholars as potentially foreshadowed by or related to this prophecy, without full scholarly consensus on a single definitive historical fulfillment to date.
Imam an-Nawawi, in placing this hadith second in Riyad as-Salihin immediately following the famous 'actions are judged by intentions' hadith, is understood by later commentators on his work to be deliberately escalating the lesson: where the first hadith teaches the principle in ordinary terms (migration for worldly gain versus migration for Allah), this second hadith extends the exact same principle to its most extreme possible application, a shared catastrophic fate, showing that the intentions principle holds even when the outward, physical consequence appears identical for everyone involved.
Putting it into practice
This hadith teaches Muslims not to judge their own spiritual standing, or that of others, purely by outward circumstances, especially unfortunate ones shared with a group. If someone finds themselves caught up in a difficult, even scandalous, situation through no genuine wrongdoing of their own, whether professionally, socially, or otherwise, this hadith is a reminder that Allah judges according to the sincerity of their actual intention and involvement, not merely their physical presence or association.
A second, more personal application is to use this hadith as a prompt for regular self-examination of intention, particularly before engaging in group activities, whether religious, charitable, professional, or social. Before joining any collective action, a person can pause and ask themselves honestly what their true motivation is for participating, since this hadith illustrates in the most extreme possible terms that Allah's judgment cuts through group identity entirely and rests solely on the individual heart.
The Prophet's character ﷺ
This hadith reveals the Prophet's ﷺ patient willingness to fully engage with Aisha's probing follow-up question rather than treating the prophecy as a closed, unquestionable pronouncement, demonstrating both his comfort with sincere theological inquiry and his consistent emphasis, across countless teachings, on the primacy of inner intention over outward appearance or association.
Companion spotlight
Aisha bint Abi Bakr, as one of the Prophet's ﷺ wives and among the most prolific narrators of hadith in Islamic history, was uniquely positioned to receive and preserve reports touching on future events and matters of unseen knowledge, given the trust and closeness the Prophet ﷺ extended to her in private conversation, and her characteristic habit of following up prophetic statements with clarifying questions, exactly as seen here, made her narrations particularly rich sources of both the original teaching and its practical elaboration.
Through a companion's eyes
He told me of an army that would one day march against the sacred House itself, and that the earth would open and take every last one of them, front to back. I could not help myself; I asked how that could be just, when such an army would surely carry along with it merchants seeking only profit and others who never truly meant harm to the Ka'bah at all.
His answer settled something in my heart that has stayed with me every day since: they will indeed all be swallowed together, but each of them will rise again according to what was truly in their own heart, not according to the company they kept. I have never since looked at any group of people, good or troubled, without remembering that Allah sees past every crowd into every single soul. (Creative narrative based on authentic hadith)
Differences of opinion
Scholars differ somewhat on the precise historical timing and identity of the army described in this hadith, with some connecting it firmly to end-times events preceding the appearance of the Dajjal, and others discussing whether certain historical assaults on Makkah in the early Islamic centuries, though ultimately unsuccessful and not accompanied by any recorded supernatural event, might represent partial or symbolic echoes of this prophecy rather than its literal fulfillment; the majority scholarly position maintains that the full, literal event described remains a future sign of the End Times that has not yet occurred.
A prophetic insight
This hadith describes a specific future geological event, the sudden swallowing of an entire army by the earth at a named location, centuries before any scientific understanding of phenomena such as sinkholes or seismic land subsidence existed; while scholars are careful to treat this as an unfulfilled sign of the Hour rather than a historically verified event to date, it is frequently cited among prophetic statements describing precise future occurrences whose fulfillment, according to Islamic eschatological belief, is still to come.
What would you do?
You learn that an organization you volunteer with, which you joined purely to help a cause you care about, has some other members who seem to be involved mainly for personal recognition or networking benefits rather than genuine concern for the cause. Reflecting on how this hadith separates individual intention from shared outward circumstances, how would you think about your own continued involvement and your own intention, regardless of what motivates others around you?
Sahih: authentic, with a sound chain of narrators.