Published on

Does Masturbation Break Your Fast? The Clear Islamic Ruling

Authors
  • Ahmad
    Name
    Ahmad
    Role
    Senior Marketing Manager, Islamic education • Deen Back

بِسْمِ اللهِ الرَّحْمٰنِ الرَّحِيْمِ

In the name of God, the Most Gracious, the Most Merciful.

This question deserves a direct answer because avoiding it only adds shame to a struggle that is already difficult enough.

The fast is sacred. The nafs is real. And for many Muslims, Ramadan — with its heightened spiritual environment and its disruption of daily routines — can paradoxically become a time when sexual urges are more difficult to manage, not less.

Let's deal with this honestly.

The Short Answer

Yes — masturbation with ejaculation breaks the fast. This is the position of all four major madhabs and the scholarly consensus.

What follows: the fast must be continued without eating or drinking for the rest of the day, and then the day must be made up (qada) after Ramadan. There is no kaffarah (expiation such as freeing a slave or feeding the poor) required — only qada. The kaffarah is reserved for marital relations during fasting hours, not masturbation.

The Evidence

The things that break the fast (muftirat as-sawm) are clearly established in the Sunnah and scholars' analysis of it. At the core is the principle that the fast is broken by any intentional satisfaction of a physical desire that the fasting person has voluntarily caused — eating, drinking, and sexual release all fall into this category.

Allah says:

فَالْآنَ بَاشِرُوهُنَّ وَابْتَغُوا مَا كَتَبَ اللَّهُ لَكُمْ ۚ وَكُلُوا وَاشْرَبُوا حَتَّىٰ يَتَبَيَّنَ لَكُمُ الْخَيْطُ الْأَبْيَضُ مِنَ الْخَيْطِ الْأَسْوَدِ مِنَ الْفَجْرِ

"...and eat and drink until the white thread becomes distinct to you from the black thread at dawn."

— (Surah Al-Baqarah, 2:187)

The verse permits marital relations only at night — which implies sexual satisfaction during fasting hours is prohibited. Scholars have applied this prohibition to all forms of intentional sexual release, including masturbation.

The hadith of the divine speech (hadith qudsi) establishes the nature of fasting directly:

يَدَعُ طَعَامَهُ وَشَرَابَهُ وَشَهْوَتَهُ مِنْ أَجْلِي

Yada'u ta'amahu wa sharabahu wa shahwatahu min ajli

"He gives up his food, his drink, and his desires for My sake."

— (Sahih Bukhari 1894)

Shahwah — desire. The fast is explicitly a restraint of desire, of which sexual desire is a primary component. Intentional satisfaction of that desire during fasting hours breaks what the fast is built on.

The Details and Common Cases

Ejaculation versus no ejaculation

This is the operative distinction in fiqh:

  • With ejaculation: Fast is broken (invalidated). Requires qada. Masturbation is also sinful and requires tawbah.
  • Without ejaculation: The fast is not technically broken according to the majority. However, the act itself is sinful and may lead to ejaculation if continued. Stop immediately and make tawbah.

What about ejaculation without intention (wet dreams)?

Wet dreams during the fasting day do not break the fast. The Prophet ﷺ was clear that the fast is broken only by intentional acts. A wet dream is not chosen, and thus does not invalidate the fast. Ghusl (full ritual purification) is still required, but the fast continues.

What if I am fasting a voluntary fast, not Ramadan?

The ruling is the same for voluntary fasts — masturbation with ejaculation invalidates the fast. The difference is that for a voluntary fast, you do not need to make it up (qada is not obligatory for nafl fasts), but you should make tawbah.

What if I forgot I was fasting?

If you genuinely forgot you were fasting and acted without remembering, the majority position is that the fast is not broken — but this applies more clearly to eating and drinking. For deliberate acts like masturbation, forgetting is less applicable as an excuse, since the act itself involves deliberate intention. Scholars generally hold that the fast is still broken in this case.

Don't Let Shame Make This Worse

Here is what usually happens: the fast breaks, shame enters, and the nafs converts that shame into an excuse to abandon the rest of the day's effort ("what's the point now?"), and sometimes the rest of Ramadan.

This is exactly what shaytan wants.

The ruling is clear: continue not eating or drinking even after the fast breaks in this way. The day is not wasted — you are still maintaining the outward fast even if the full reward is lost. And a sincere tawbah, made with genuine regret and firm intention, is accepted by Allah.

The person who falls and gets up immediately — that is not a hypocrite. That is a believer.

The deeper work here is building real self-control. Fasting is designed to train the nafs. If masturbation is a recurring struggle during and outside of fasting, that is a sign that the nafs needs consistent training, not just seasonal willpower. See how to quit pornography islamically for practical frameworks if this struggle is connected to a broader pattern.

Train the Nafs Year-Round, Not Just in Ramadan

DeenBack helps you build the daily self-control habits that make Ramadan easier — and that carry the discipline of fasting into the rest of your life.

Download on the App StoreGet it on Google Play

Free download. Premium features available in-app.

Quick Reference

SituationFast broken?Qada required?Kaffarah?
Masturbation with ejaculationYesYesNo
Masturbation without ejaculationNo (majority)NoNo
Wet dream during fastNoNoNo
Marital relations during fastYesYesYes (kaffarah)

Common Questions

I already broke my fast this way — do I tell anyone in my family?

No. This is between you and Allah. You are not required to disclose it to family. Continue not eating or drinking for the rest of the day, make up the day after Ramadan, and make sincere tawbah.

If I broke my fast, can I still get any reward for that day?

Not the full reward of a valid fast. But your continued restraint from eating and drinking, your salah, your dhikr, your good deeds throughout the rest of the day — all of these carry their own rewards. One broken fast does not erase all worship.

This happens to me every Ramadan. What should I do differently?

Look at the environment and the triggers. Ramadan disrupts sleep schedules and routine, which can lower self-control. Practical steps: maintain a structured sleep pattern, increase Quran recitation as a replacement activity in idle moments, fast the permitted hours of the day with community (iftar with others rather than alone), and use the dhikr practices of seeking refuge in Allah specifically. The dua for self-control and dua for resisting nafs are worth incorporating.

Is masturbation always haram or only during fasting?

Masturbation is generally prohibited in Islam. The Quran commands believers to guard their private parts except in marriage: "And those who guard their private parts" (Surah Al-Mu'minun, 23:5). The majority of scholars hold that masturbation is not among the permitted exceptions. During fasting, the sin is compounded by the breaking of the fast.

The Path Forward

This is not a topic where you should carry silent shame. The question you searched today is being searched by thousands of Muslims who are genuinely trying to do better.

The honest first step — acknowledging the struggle rather than papering over it — is the right one. See what breaks your fast for the complete picture of fast-invalidators.

Your Nafs Can Be Trained — Start Today

DeenBack tracks your daily self-control habits and dhikr practice — helping you build the sustained inner discipline that Ramadan alone cannot create.

Download on the App StoreGet it on Google Play

Free download. Premium features available in-app.

Frequently Asked Questions

Does masturbation break the fast in Islam?

Yes. According to the consensus of all four madhabs, masturbation that results in ejaculation (or orgasm for women) breaks the fast. The day must be completed without eating or drinking, then made up (qada) after Ramadan. No kaffarah (expiation) is required — only qada.

What if I started but stopped before climax?

If no ejaculation occurred, the fast is not technically invalidated according to the majority of scholars. However, you have committed a sin and must make tawbah. Some scholars from the Hanbali school are more cautious on this point, but the mainstream position is that the fast remains valid if there was no ejaculation.

Is masturbation during fasting worse than at other times?

Yes. Masturbation is generally prohibited in Islam (based on Surah Al-Mu'minun, 23:5-7). During fasting, it carries the additional sin of breaking the sanctity of the fast. The gravity is compounded, though only one qada is required — not kaffarah.

Do I have to tell anyone that I broke my fast this way?

No. Tawbah is between you and Allah. You do not need to inform an imam, your family, or anyone else. You simply make tawbah, continue your fast for the rest of the day (you must still not eat or drink), and make up the day after Ramadan.

What if this is a recurring struggle during Ramadan?

This is more common than people admit. The key is to treat it as a nafs-management challenge, not a reason to give up on fasting. Specific steps help: fasting with a clear environment, reducing triggers, increasing dhikr, and building the underlying self-control habit.