Headache is connected with sleep quality, e.g. hypnic headache and chronic paroxysmal headache attacks occur preferentially during REM sleep; this is possibly also true for cluster headache and migraine. REM sleep is typically characterized by the occurrence of ponto-geniculo-occipital spikes (PGOs). These PGOs should be able to trigger cortical spreading depression (CSD), which, although often clinically silent, is assumed to be an essential element of a migraine attack and possibly also of other forms of headache. CSDs are considered a correlate of migraine aura. They could lead to the secondary activation of trigeminovascular afferences, which would then induce a headache. Interestingly, illnesses that are comorbid with migraine cause an increase in the amount of REM sleep; conversely, various drugs administered prophylactically for these illnesses reduce the quantity of REM sleep.