A Muslim should never surrender to depression, despair, or evil thoughts. A Muslim should seek refuge in Allah and seek His help against these evils. At the same time, medical treatment should not be ignored.
Sheikh Muhammad Nur Abdullah, President of the Islamic Society of North America (ISNA) and member of the Fiqh Council of North America states:
This is common among women after giving birth, especially after the first delivery. Every Muslim woman that finds themselves in such situation needs to take medication prescribed to them by the doctor.
Also, they need to regularly perform their salah (ritual Prayer) and have specific time to make dhikr (remembrance of Allah) every day. Always read Ayat Al-Kursi (Al-Baqarah 255) and the last two surahs, Al-Falaq and An-Nas (known together as Al-Mu`awidhatayn). Also read the du`aa’ (supplication) for one with worries in which the Prophet (peace and blessings be upon him) used to say:
‘O Allah, I seek refuge in You from worry and sorrow, and from helplessness and laziness, and from cowardice and miserliness, and from being overwhelmed by debt or humiliated by people.’