وَيَسۡـَٔلُونَكَ عَنِ ٱلۡمَحِيضِۖ قُلۡ هُوَ أَذٗى فَٱعۡتَزِلُواْ ٱلنِّسَآءَ فِي ٱلۡمَحِيضِ وَلَا تَقۡرَبُوهُنَّ حَتَّىٰ يَطۡهُرۡنَۖ فَإِذَا تَطَهَّرۡنَ فَأۡتُوهُنَّ مِنۡ حَيۡثُ أَمَرَكُمُ ٱللَّهُۚ إِنَّ ٱللَّهَ يُحِبُّ ٱلتَّوَّٰبِينَ وَيُحِبُّ ٱلۡمُتَطَهِّرِينَ ٢٢٢
They ask thee concerning women's courses. Say: They are a hurt and a pollution: So keep away from women in their courses, and do not approach them until they are clean. But when they have purified themselves, ye may approach them in any manner, time, or place ordained for you by Allah. For Allah loves those who turn to Him constantly and He loves those who keep themselves pure and clean.
wayas’aluunaka ‘ani almahiidi qul huwa ’azan fa‘taziluu annisaa’a fii almahiidi walaa taqrabuuhunna hattaa yathurna fa’izaa tatahharna fa’tuuhunna min haysu ’amarakumu allaahu ’inna allaaha yuhibbu attawwaabiina wayuhibbu almutatahhiriina
Some Qur'anic exegetes said: “When a woman was in her period of menstruation, the pre-Islamic Arabs used to refrain from eating, drinking with her and also from staying with her in the same house, exactly as was the habit of the Magians. Abu'l-Dahdah asked the Messenger of Allah, Allah bless him and give him peace, about this saying: 'O Messenger of Allah! What should we do with women when they are in their menstruation?' As a response, Allah, exalted is He revealed this verse”.