Short answer
A job is haram when the work itself is a sin or directly serves one: making or selling alcohol, pork, drugs or gambling, dealing in interest, fortune telling, prostitution and indecent entertainment, and work built on lying or cheating. Jobs with only a remote link to someone else's sin are usually allowed, though better avoided.
Earning from work that is itself sinful, or that directly helps a sin, is haram and the pay is impure. When your own work is lawful and any link to another person's sin is indirect, such as cleaning a bank or renting out a house the tenant later misuses, the Hanafi school allows it, though it is better to avoid.
Other madhhabs
- Shafi'i
- Stricter on indirect help: selling or renting something to a person known to use it for sin is haram.
- Maliki
- Stricter on indirect help: a sale or rental to someone known to use it for sin is forbidden.
- Hanbali
- Stricter on indirect help: such a sale or rental is forbidden and, in the school's main view, invalid.
Explanation
Most work is halal. The Prophet ﷺ praised eating from the work of your own hands, and the default in work and trade is permission. A job becomes haram for one of these reasons:
- The product is haram: alcohol, pork, drugs, gambling, pornography. When Allah forbids something, He forbids its price too.
- The service is haram: interest-based lending, conventional insurance sales, fortune telling and astrology, prostitution, music and dance as entertainment in the Hanafi view.
- The method is haram: scams, high-pressure lies, hiding defects, bribes.
- It directly enables a sin: serving alcohol, drafting interest contracts, promoting gambling.
The Hanafi school separates direct help (haram) from a remote cause (allowed). Allah says "do not cooperate in sin and aggression" (5:2), and a cashier who rings up beer is cooperating directly. A software engineer at a general company, a cleaner in an office tower or a builder whose building is later used by a bank is not, because the sin, if any, is the free choice of someone else. The other schools are stricter here.
Answers on specific jobs: bank or insurance company, restaurants serving alcohol or pork, delivery driving, lawyer, modeling and YouTube.
If you are in a haram job now, start looking for halal work straight away and leave as soon as you reasonably can without leaving your family in need. How to treat the income you have already earned depends on the details, so ask a mufti.
Ask a mufti about your own case. This answer explains the general ruling. When the details of your situation matter, as they do here, ask a qualified mufti and give them the full facts. Where to ask a scholar.
The evidence
Quran, Surah Al-Maaida 5:2
يَٰٓأَيُّهَا ٱلَّذِينَ ءَامَنُوا۟ لَا تُحِلُّوا۟ شَعَٰٓئِرَ ٱللَّهِ وَلَا ٱلشَّهْرَ ٱلْحَرَامَ وَلَا ٱلْهَدْىَ وَلَا ٱلْقَلَٰٓئِدَ وَلَآ ءَآمِّينَ ٱلْبَيْتَ ٱلْحَرَامَ يَبْتَغُونَ فَضْلًۭا مِّن رَّبِّهِمْ وَرِضْوَٰنًۭا ۚ وَإِذَا حَلَلْتُمْ فَٱصْطَادُوا۟ ۚ وَلَا يَجْرِمَنَّكُمْ شَنَـَٔانُ قَوْمٍ أَن صَدُّوكُمْ عَنِ ٱلْمَسْجِدِ ٱلْحَرَامِ أَن تَعْتَدُوا۟ ۘ وَتَعَاوَنُوا۟ عَلَى ٱلْبِرِّ وَٱلتَّقْوَىٰ ۖ وَلَا تَعَاوَنُوا۟ عَلَى ٱلْإِثْمِ وَٱلْعُدْوَٰنِ ۚ وَٱتَّقُوا۟ ٱللَّهَ ۖ إِنَّ ٱللَّهَ شَدِيدُ ٱلْعِقَابِ ﴿٢﴾
O you who have believed, do not violate the rites of Allah or [the sanctity of] the sacred month or [neglect the marking of] the sacrificial animals and garlanding [them] or [violate the safety of] those coming to the Sacred House seeking bounty from their Lord and [His] approval. But when you come out of ihram, then [you may] hunt. And do not let the hatred of a people for having obstructed you from al-Masjid al-Haram lead you to transgress. And cooperate in righteousness and piety, but do not cooperate in sin and aggression. And fear Allah; indeed, Allah is severe in penalty.
Work that directly helps sin is forbidden cooperation.
Sahih al-Bukhari 2237
Sahih... نهى عن ثمن الكلب ومهر البغي وحلوان الكاهن ...
"He forbade the price of a dog, the earnings of a prostitute and the fee of a soothsayer."
Some earnings are unlawful because the work behind them is unlawful.
Sunan Abi Dawud 3488
Graded sahih hadith... إن الله إذا حرم على قوم أكل شيء حرم عليهم ثمنه ...
"When Allah forbids a people to consume something, He forbids them its price."
Selling a haram product is as unlawful as consuming it.
Sahih al-Bukhari 2072
Sahih... ما أكل أحد طعاما قط خيرا من أن يأكل من عمل يده ...
"No one has ever eaten better food than what he eats from the work of his own hands."
Lawful work is praised; permission is the default.
Where the ruling is recorded
- al-Hidaya, Kitab al-Karahiya, section on sale (fasl fi al-bay'). Abu Hanifa's distinction between direct help in sin and a remote cause, such as renting a house to a tenant who sins in it.
- Radd al-Muhtar (Ibn Abidin), Kitab al-Hazr wa al-Ibaha. Explains when helping in sin is haram and when the link is too remote to count.
Checked by our team. For a more accurate answer to your own situation, consult a scholar. Quran translation by Sahih International. Hadith Arabic from the standard editions of the six books and the Muwatta, with gradings as recorded there; the English is our own rendering. Spotted a mistake? Tell us.