Answered by Shaykh Amjad Rasheed
Prayer of a woman during childbirth
It is obligatory for a pregnant woman or any other woman to pray as long as she is still sane. However, the shari`ah is lenient for the sick person, like the pregnant woman, in how to perform the prayer. If it is difficult for her to stand, she may pray sitting and she may perform ruku` (bowing) while sitting and perform her prostration by touching the ground. If she is unable to sit, she may pray while in bed/reclining/ lying down on her right side, or left side, however she wishes. She can then perform the ruku` and the prostration as we mentioned. If she is unable, she may pray lying down on her back facing the qiblah with her face and the soles of her feet, and she may perform the ruku` and the prostration as we mentioned. If performing the ruku` and the prostration is difficult for her, then she may motion the movements with her head and that is sufficient. However, if she is not able to move any part of her body, she may make the motions of the integrals of the prayer with her eyes. If she can’t even do that, she may go through the integrals of the prayer in her heart and Allah is Most Generous with His bounty to accept it from her as He said, Most High, “And He has not made for you any hardship in religion.”
The most reliable position in our school is that it is not permissible for a sick person to join his prayers, however some of our imams such as Imam al-Nawawi, have chosen to permit it for a sick person for whom it is difficult to perform the prayers in their times. So he may join dhuhr and asr, or maghrib and `isha in the first of the two times, or the later of the two, according to what is easier. Imam Khatib al-Shirbini said in the Mughni, “And this is what is in best accordance to the beauties of the shari`ah, for He, Most High, has said, And He has not made any hardship for you in religion.'”
– Amjad Rasheed
(Translated by Shazia Ahmad)