Pornography and Masturbation
In the name of Allāh, the Most Gracious, the Most Merciful.
In this era of high-tech progression, accessing data and retrieving information has become far easier than before. Numerous inventions have taken place in the last few decades which have served positively for the comfort of people. Islām permits the utilisation of such inventions within the confines of Sharī‘ah, and prohibits the usage of that which is detrimental to ones’ physicality and spirituality.
Just as technological advancements hold many advantages, similarly, they have many disadvantages and harms. One such harm is, sexual exploitation in its various forms. Many avenues have opened up which allow one to access the filth of pornography which in reality is ‘fake’ and ‘illusionary’. Porn is aimed to spring instant stimulation to ones’ libido leading one towards satisfying himself, i.e. masturbating which in return can cause damage to ones’ health and spirituality. The more pornography one views, the more severe the damage caused to ones’ brain. 
Those who have a habit of viewing pornography, generally do so at night. They spend the day working and the night watching filth. They are overcome with restlessness and are deprived of sleep. Sleep deprivation is a one-way ticket to mental instability. If reading pornographic magazines, watching filthy movies, being involved in some illicit relationship and indulging in other sins does not result in any remorse or sorrow, (and instead we are expressing happiness over it) then where is our Īmān? 
As for masturbation, it also causes many harms. Fuqahā (Jurists) have classified masturbation as impermissible and a detested act in Sharī‘ah. 
Few excerpts of texts from the books of Fiqh on the prohibition of Masturbation
Ibn ābidīn al-Ḥanafī: “Self-pleasuring is not permissible due to the verse of the Qur’ān in Sūrah al-Mu’minūn – “And those who guard their private parts….” One may derive pleasure through one’s wife…” (Radd al-Muḥtār. See endnote 3)
Ṣalāḥ Abu l-Ḥāj al-Ḥanafī: “Know well, it is prohibited for one to masturbate. However, if one is in a situation wherein he is about to fornicate, then only would it be permissible for him to masturbate to avert the desire of fornication.” (Fatāwā Ṣalāḥ Abu l-Ḥāj. See endnote 3)
Al-Imām al-Shāfi’ī: “Verse 5 in Sūrah al-Mu’minūn establishes that to derive pleasure from anything/anyone besides ones’ wife is prohibited.” (Al-Umm. See endnote 3)
Abū Bakr ibn Muḥammad al-Husaynī al-Shāfi’ī: “The one who seeks pleasure with his hand will be punished because doing so is the same as committing fornication and adultery. It also discontinues procreation, hence, it is prohibited.” 
Yaḥyā ibn Sharaf al-Nawawī al-Shāfi’ī: “Masturbation is Ḥarām (prohibited) and it is punishable.” 
“To ejaculate without sexual intercourse (through halal means) is Ḥarām just as masturbation (to ejaculate by using ones’ hand) is Ḥarām.” 
‘Abd al-Ḥayy al-Lakhnawī al-Ḥanafī: “Masturbation is prohibited and it is a filthy act. It invalidates the fast of the one who observes fasting.” 
Ibn Dhuwayyān al-Ḥanbalī: “Masturbation is impermissible for men and women because of the verse of the Qur’ān in Sūrah al-Mu’minūn…” 
Abu l- ‘Abbās Aḥmad ibn Aḥmad Zarrūq al-Mālikī: “The Madhhab of Imām al-Shāfi’ī and Imām Mālik is that masturbation is not permissible….” 
After reading the statements of the Fuqahā, one can easily conclude that the act of masturbation is considered to be unlawful in Sharī‘ah. However, there may be instances when one is in a situation to choose between imminent zinā or masturbation. In such cases, the jurists have stated that if one opts for masturbation then it is hoped, Allāh Ta‘ālā may not punish him. 
Some practical ways to refrain from pornography and masturbation
- Firstly, one should seek assistance from Allāh Ta‘ālā. Willpower without Allah’s power and His support is of no use. One should make a habit of sitting in a secluded area daily and supplicating to Allāh.
- Murāqabah – to reflect over ones’ actions, sins and deeds while pondering how this sin of masturbation could eventually lead to a miserable life full of loneliness and displeasure of Allāh Ta‘ālā. One should also contemplate over death and think, what would happen if I die whilst indulging in viewing pornography and masturbation.
- Consult a senior scholar who is involved in making Iṣlāh (spiritual reformation) and inform him of one’s evil habits. The Mashāyikh prescribe doses of ‘spiritual medicine’ from the Qur’ān and recommend various Adhkār which remove the dirt from the heart and instils the love of Allāh, his messenger (Ṣallallāhu ‘alayhi wa sallam) and an earnest desire to follow the dīn properly.
- Minimise usage of the internet. It is extremely important that one cuts down on using the internet and unnecessary browsing when unoccupied. One should fill his day with fruitful activities that occupy his time in a positive way. Remember, “An idle mind is a devils’ workshop”.
- It is also possible to change the internet settings to prevent access to such websites. One should also download software/apps such as Net nanny or K9 internet watch, which are specifically designed for controlling web content for safe browsing.
- At the same time, download plugins for one’s browser which removes adverts as well as disables pictures. Once one has realized that these elements are catalyst for one’s sexual problem, it only makes sense that one quarantines himself. Such measures are akin to any other medical restriction to safeguard one’s Īmān.
- Read Islāmic literature and sit with the scholars. Many Masājid hold weekly programmes for the general people.
- Take assistance from the words of Allāh, i.e. Qur’ān. Recitation of Qur’ān as a daily practice, or even listening to it on a regular basis curbs the heightened desires of the heart.
- Regulate one’s food. Many foods which have heat in them heighten sexual libido. Reduce such foods like dates, read meat, almonds, seafood and many citrus fruits.
- Fast regularly. Fasting assists in controlling one’s sexual desire as prescribed by our Beloved Messenger (Ṣallallāhu ‘alayhi wa sallam).
Many of these tips have proven to be effective in occupying one’s mind and removing the urge to indulge in this vice. Lastly, remember, “Success comes in cans, not in cannot’s.”
May Allāh ‘azza wa jal protect us from all vices which earn his displeasure and wrath and may Allāh protect us from the snares of Shayṭān, āmīn.
Bilal Issak al-Mahmudi
Checked and Approved by,
Mufti Faisal al-Mahmudi