Umar ibn al-Khattab (RA) → 'Alqamah ibn Waqqas al-Laythi → Muhammad ibn Ibrahim al-Taymi → Yahya ibn Sa'id al-Ansari → Sufyan ibn 'Uyaynah → Qutaybah ibn Sa'id → Imam al-Nasai
I heard the Messenger of Allah ﷺ say: Actions are only by intentions, and every person has only what he intended. So whoever migrated to Allah and His Messenger, then his migration is to Allah and His Messenger. And whoever migrated to attain worldly gain or to marry a woman, then his migration is to that which he migrated for.
Explanation
The Sunan an-Nasai opens with this luminous hadith of intention, and in the context of al-Nasai's compilation — which is widely regarded as the most rigorous of the six canonical hadith collections (al-kutub al-sittah) in terms of the strength of its chains — its placement here carries its own specific scholarly significance. Al-Nasai was known for his exceptionally high standards in isnad evaluation, and his inclusion of this hadith at the very head of his Sunan through the strongest available chain — through Yahya ibn Sa'id al-Ansari, who is the most authoritative transmitter of this hadith — is a deliberate endorsement of its position as the gateway to all of Islamic legal knowledge.
The hadith's opening word, 'innamal,' is a particle of restriction (hasr) in Arabic, signifying that the statement is exclusive: actions do not merely benefit from intentions — they exist and have value only because of and in proportion to intentions.
Al-Nasai's Sunan, also known as al-Mujtaba (the selected), covers primarily rulings relating to purification, prayer, zakah, fasting, hajj, marriage, and trade — the full spectrum of Islamic legal life. By placing this hadith of intention at the head of all these rulings, al-Nasai signals that the entire edifice of Islamic law is built on the foundation of the heart's orientation. A Muslim who performs every prayer with correct form but without sincerity, who pays zakah only to be seen, who fasts while nurturing resentment and dishonesty in the heart — such a person fulfills the outward letter of Islamic law while emptying it of its spiritual core. The niyyah is what converts an act from a mere social compliance into a genuine act of worship.
When and why it was said
Ahmad ibn Shu'ayb al-Nasai (214–303 AH) was born in Nasa in Khurasan (modern-day Turkmenistan) and traveled extensively throughout the Islamic world to collect hadith before settling in Egypt, where he taught for many years and compiled his Sunan. He died in Palestine, reportedly as a result of injuries sustained when he was beaten by a crowd in Damascus after he praised the virtues of 'Ali ibn Abi Talib (RA) and was perceived as slighting the Umayyad legacy — a testament to his uncompromising scholarly honesty even at personal cost. His Sunan is distinctive for the high proportion of hadith deemed sahih compared to other collections of equal breadth, and he was meticulous to a degree that some scholars considered extreme.
The chain through which al-Nasai transmits this hadith — through Qutaybah ibn Sa'id from Sufyan ibn 'Uyaynah from Yahya ibn Sa'id al-Ansari — is the most widely cited and most robust chain of this hadith. Yahya ibn Sa'id al-Ansari (died 143 AH) was a renowned judge in Madinah and one of the most trusted Tabi'in (successors to the companions), and his transmission of this hadith through Muhammad ibn Ibrahim al-Taymi from 'Alqamah ibn Waqqas from Umar ibn al-Khattab became the canonical version.
Imam al-Shafi'i reportedly said of this chain that he knew of no other hadith that had been transmitted through so many different scholars from Yahya ibn Sa'id — over two hundred scholars narrated it from him alone — making it one of the most widely transmitted hadiths in the history of the religion despite having a single link at its earliest stage.
What the scholars said
Imam al-Nasai's own commentary on his selections, as preserved through his students and reflected in works like Khasa'is 'Ali, reveals a scholar who was deeply attentive to the spiritual dimensions of hadith alongside their legal applications. For this opening hadith, later commentators on his Sunan — including Imam al-Suyuti and Imam al-Sindi, both of whom wrote supercommentaries on Sunan al-Nasai — note that al-Nasai's chain through Yahya ibn Sa'id is considered the strongest and most direct of all the chains of this hadith, which is part of why al-Bukhari also chose this chain for his own transmission in Sahih al-Bukhari.
The fifteenth-century scholar Imam al-Suyuti, in his commentary Zahr al-Ruba 'ala al-Mujtaba on Sunan al-Nasai, discusses the significance of al-Nasai opening his collection with this hadith and notes the consensus among the great imams — al-Shafi'i, Ahmad ibn Hanbal, and Ibn Mahdi — that this hadith alone is sufficient as a foundation for all religious knowledge. Imam Ahmad ibn Hanbal famously stated that Islam rests on three hadiths: the hadith of intentions (this one), the hadith of 'whoever introduces into this matter of ours what is not from it,' and the hadith of 'the halal is clear and the haram is clear.' Together, these three govern the internal (intention), the formal (innovation), and the ethical (halal and haram) dimensions of Islamic practice.
Putting it into practice
Al-Nasai's rigorous standards invite us to apply similar rigour to our own intentions. Make it a practice to regularly evaluate not just what you are doing but why. One powerful technique is the 'intention journal': keep a small notebook or notes app entry where, at the end of each day, you record two or three acts you performed and honestly assess your motivation for each. Were you patient with your child because you love them and seek Allah's pleasure, or because you were tired and lacked the energy to react?
Did you help your colleague because you genuinely care, or to build social capital? This exercise is not about self-condemnation but about developing the self-awareness that this hadith demands. Over time, consistent reflection on intention creates a habit of sincerity, and the habit of sincerity eventually transforms into a natural orientation of the heart.
A second practical application is what scholars call tajdid al-niyyah — the renewal of intention. During any extended act — a long recitation of Quran, a multi-hour volunteer project, a month of fasting — our initial sincere intention can fade and be replaced by habit, social inertia, or the desire to avoid disruption. Build in deliberate moments of intention renewal: halfway through Ramadan, pause and ask yourself sincerely why you are fasting.
Before the last third of Tahajjud prayer, renew your intention internally. Before continuing to volunteer at the same community project you have been doing for years, pause and reconnect with the reason. These moments of intentional renewal prevent worship from ossifying into mere habit and keep the connection between the outer act and the inner heart alive and active.
The Prophet's character ﷺ
This hadith, through the lens of al-Nasai's scholarly rigour, reveals the Prophet ﷺ as someone whose teaching reached beyond the merely observable. Al-Nasai and his predecessors preserved this hadith because the Prophet ﷺ was addressing the most interior dimension of human religious life — the place that no one can legislate, no judge can evaluate, and no community can enforce. His insistence on the centrality of niyyah reflects his understanding that the religion he was establishing would eventually become, for some people, a social identity rather than a living relationship with Allah. The hadith is his prophylactic against that decay: always return to the interior, always ask why, always let the heart be the primary judge of the act.
Companion spotlight
Umar ibn al-Khattab (RA) was one of the ten companions given the glad tidings of Paradise (al-'ashara al-mubashsharun bil-jannah), and his character was defined by a combination of extraordinary strength and profound spiritual sensitivity. He was famous for weeping in his night prayers, for his harsh treatment of himself in accounting for his own shortcomings, and for his burning sense of justice that extended equally to the most powerful and the most vulnerable in his society. His role as the sole early narrator of this hadith about intentions is seen by scholars as providential: a man of such penetrating self-accountability was the ideal vessel for a teaching that demands the same penetrating self-examination from every Muslim.
Through a companion's eyes
I heard the Prophet ﷺ say this again today, and I recorded it in my heart as I have done before. Each time he speaks of niyyah I feel it land differently. This time I was thinking about how many of us in the community appear to do the same acts — the same prayers, the same fasting, the same giving — and yet we know, and Allah knows, that we are different inside.
One man prays because he loves Allah. Another prays because his family expects it. Another prays to be seen as religious. From the outside, three men in the same row of prayer. Before Allah, three entirely different acts. The Prophet ﷺ has given us a teaching that makes each of us alone with our own heart, responsible for what only we and our Lord can see. There is no deceiving this reckoning.
I pray that when I stand before Allah, what He finds in my heart bears some resemblance to what I have tried to show the world. (Creative narrative based on authentic hadith)
What would you do?
You have been involved in Islamic charitable work for many years and have developed a reputation as a generous and committed Muslim activist. A major Islamic organisation invites you to join their board, which would significantly raise your public profile. You notice that a part of your excitement about this opportunity stems not from the additional good you could do but from the social recognition it would bring. How do you apply the principle of niyyah to this decision — and if you decide to accept, what specific internal disciplines would you adopt to ensure that your motivation remains primarily for Allah's sake rather than for the elevation of your own standing?
Sahih: authentic, with a sound chain of narrators.