Praise be to Allaah.
Epilepsy in most cases is caused by the jinn, and in some cases by some defect in the body, brain or nerves, or mood swings, or some weakness in the physical structure. All of these may cause loss of consciousness or unbalanced behaviour. The black woman’s epilepsy may have been caused by the jinn, but there was no need to mention the cause, which is why the narrators only mentioned what needs to be done when epilepsy occurs, for whatever reason, of making du’aa’ and performing ruqyah, or bearing it with patience and seeking the reward from Allaah.
Shaykh ‘Abd al-Kareem al-Khudayr
The hadeeth about the black woman is narrated in Saheeh al-Bukhaari (5652) and Saheeh Muslim (2576). In some versions of the hadeeth there is an indication that her epilepsy was caused by the jinn. For example, in a version narrated by al-Bazzaar, she said, “I am afraid that the evil one may cause me to become uncovered.” Al-Haafiz Ibn Hajar said: “It may be understood from some of the different versions of the hadeeth that what Umm Zafar was suffering from was the kind of epilepsy caused by the jinn and not that which results from dysfunction in the brain.”
Fath al-Baari, hadeeth no. 5652.