Praise be to Allah.
One of the problems with which many Muslims are faced nowadays is the prevalence of free mixing in universities, hospitals, most public facilities and government workplaces.
We have previously explained the prohibition on free mixing and the negative consequences that result from it, in the answer to question no. 1200, where we stated that it is obligatory for the Muslim to avoid studying and working in mixed environments.
But in the countries where the people are faced with the problem of mixing in most fields of life, especially educational centres and workplaces, to the extent that it has become extremely difficult for the Muslim to protect himself from that, a concession is granted to them that is not granted to others whom Allah has protected from such problems.
This concession is based on the fiqhi principle that “whatever is prohibited so as to bar the means that may lead to evil may be permitted in cases of necessity and where doing so serves a greater interest.”
Shaykh al-Islam Ibn Taymiyah (may Allah have mercy on him) said:
All Islamic rulings are based on the principle that with regard to some evil that is prohibited, if there is an urgent need that outweighs, it makes that which is ordinarily prohibited permissible.
End quote from Majmoo‘ al-Fataawa (29/49).
And he said:
With regard to that which comes under the heading of barring the means (that lead to something prohibited), it is only to be prohibited if there is no need for it. But if there is a need for it in order to achieve a purpose that cannot be achieved otherwise, then it is not to be prohibited.
End quote from Majmoo‘ al-Fataawa (23/214)
Ibn al-Qayyim said:
That which is prohibited so as to bar the means (that lead to something prohibited) may be permitted if there is a clear interest to be served, or example: … naafil prayers that are offered for a specific reason are permissible after Fajr and ‘Asr (when naafil prayers that are not done for a specific reason are not allowed, until after sunrise and sunset respectively); it is permissible for one who wants to propose marriage, one who is giving testimony, a doctor and one who is party to a transaction, buying or selling, to look at a woman’s face in a manner that is ordinarily prohibited; and the prohibition on gold and silk for men is a prohibition that serves to bar the means that may lead to men imitating women, for which the one who does that is cursed, but it is permitted in cases of necessity.
End quote from I‘laam al-Muwaqqi‘een (2/161)
Shaykh Ibn ‘Uthaymeen said:
With regard to that which is prohibited in the sense of prohibiting the means (that may lead to something prohibited), it may be permitted in the case of necessity.
End quote from Manzoomah Usool al-Fiqh (p. 67)
what appears to be the case, and Allah knows best, is that in such countries where this problem (free mixing) is widespread, a concession may be granted allowing the people to study and work in mixed environments, such as is not granted to others, as stated above. But that should is subject to a number of conditions, as follows:
The individual should first of all strive hard to look for a place in which there is no mixing, as much as possible.
He should adhere to the Islamic rulings such as lowering the gaze, and not talking and engaging in conversation more than is necessary for the purpose of work or study.
Shaykh Ibn ‘Uthaymeen was asked about a young man who cannot find anything but a school that is mixed. He said: You have to look for a school that is not like this, but if you cannot find such a school, and you need to study, then you may read and study, and try to the best of your ability to keep away from immorality and temptation, by lowering your gaze, guarding your tongue, not talking to women and not walking past them.
Fataawa Noor ‘ala ad-Darb (1/103, 13/127)
If a person notices in himself an inclination towards that which is prohibited, and realises that he is being tempted by some of the women who are with him, then preserving his religious commitment takes precedence over all other interests. In that case it is essential for him to leave that place, and Allah, may He be glorified and exalted, will make him independent of means by His bounty.