Short answer
Yes. A talaq given while the wife is pregnant takes effect, and pregnancy is not one of the forbidden times like her period. Her iddah lasts until she gives birth, and he must house and provide for her until then. A revocable talaq can still be taken back before the birth. The four schools agree.
Talaq during pregnancy is valid and is a sunnah time for a single talaq, whether or not they were intimate during the pregnancy. Her iddah ends with the delivery, however soon that is. During it she has the right to maintenance and housing.
The four schools agree on this.
Explanation
When Ibn Umar divorced his wife during her period, the Prophet ﷺ told him to take her back and, if he still wished, to divorce her when she was pure or pregnant. So pregnancy is a lawful time for talaq, unlike menstruation. Allah says the iddah of pregnant women is "until they give birth" (65:4), and tells husbands to spend on them until then (65:6).
What this means:
- The talaq counts from the moment it is given. Pregnancy does not cancel or delay it.
- Iddah ends at birth. If she gives birth a week later, the iddah is over; if months later, it lasts months. Use the iddah calculator.
- Taking her back. After one or two revocable talaqs he may return to her any time before the birth. See talaq raj'i and ba'in.
- Maintenance and housing are owed until the birth, and the child's support after that is on the father. See child support.
- Miscarriage. If the baby's form had begun to show, the iddah ends with it. If not, she counts menstrual cycles instead. Ask a mufti.
Valid does not mean wise. Pregnancy is a time of strain, and many divorces said then are regretted. If you are thinking of it, wait, talk and seek counsel first. If words of talaq have already been said, give a mufti the exact words and how many times. See custody after divorce.
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 At-Talaaq 65:4
وَٱلَّٰٓـِٔى يَئِسْنَ مِنَ ٱلْمَحِيضِ مِن نِّسَآئِكُمْ إِنِ ٱرْتَبْتُمْ فَعِدَّتُهُنَّ ثَلَٰثَةُ أَشْهُرٍۢ وَٱلَّٰٓـِٔى لَمْ يَحِضْنَ ۚ وَأُو۟لَٰتُ ٱلْأَحْمَالِ أَجَلُهُنَّ أَن يَضَعْنَ حَمْلَهُنَّ ۚ وَمَن يَتَّقِ ٱللَّهَ يَجْعَل لَّهُۥ مِنْ أَمْرِهِۦ يُسْرًۭا ﴿٤﴾
And those who no longer expect menstruation among your women - if you doubt, then their period is three months, and [also for] those who have not menstruated. And for those who are pregnant, their term is until they give birth. And whoever fears Allah - He will make for him of his matter ease.
The iddah of a pregnant woman ends with delivery.
Quran, Surah At-Talaaq 65:6
أَسْكِنُوهُنَّ مِنْ حَيْثُ سَكَنتُم مِّن وُجْدِكُمْ وَلَا تُضَآرُّوهُنَّ لِتُضَيِّقُوا۟ عَلَيْهِنَّ ۚ وَإِن كُنَّ أُو۟لَٰتِ حَمْلٍۢ فَأَنفِقُوا۟ عَلَيْهِنَّ حَتَّىٰ يَضَعْنَ حَمْلَهُنَّ ۚ فَإِنْ أَرْضَعْنَ لَكُمْ فَـَٔاتُوهُنَّ أُجُورَهُنَّ ۖ وَأْتَمِرُوا۟ بَيْنَكُم بِمَعْرُوفٍۢ ۖ وَإِن تَعَاسَرْتُمْ فَسَتُرْضِعُ لَهُۥٓ أُخْرَىٰ ﴿٦﴾
Lodge them [in a section] of where you dwell out of your means and do not harm them in order to oppress them. And if they should be pregnant, then spend on them until they give birth. And if they breastfeed for you, then give them their payment and confer among yourselves in the acceptable way; but if you are in discord, then there may breastfeed for the father another woman.
Maintenance is owed through the pregnancy.
Sahih Muslim 1471
Sahih... ثم ليطلقها طاهرا أو حاملا ...
"Then let him divorce her when she is pure or pregnant."
Pregnancy is a lawful time for talaq.
Where the ruling is recorded
- al-Hidaya, Kitab al-Talaq, Bab Talaq al-Sunnah. Divorcing a pregnant wife is a sunnah divorce.
- al-Hidaya, Kitab al-Talaq, Bab al-'Iddah. The iddah of a pregnant woman ends with delivery.
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.