According to Wikipedia, 1.16 Billion people (14%) worldwide suffer from migraines. 37 Million in the US.
Migraines are caused by low seratonin levels and low serotonin levels are caused by low magnesium levels. Sumatriptan (Imitrex) stops migraine attacks because it increases seratonin levels. Serotonin is produced from tryptophan → 5-HTP → serotonin. Magnesium acts as a coenzyme at every stage of this biochemical chain. Without sufficient magnesium, serotonin production is impaired, which can lead to decreased emotional resilience, increased anxiety, low mood, sensitivity to stress, and migraines.
How do I know this? I started taking magnesium 1 year ago for sleep. The first time I took magnesium, within 10 minutes, my body and mind relaxed. A lot. I nearly fell asleep at 11AM. Then the migraines stopped. Usually, high altitude triggers a migraine within 2 hours. I was astounded after spending 2 nights at the Grand Canyon at 7000' altitude, and 3 nights at Yellowstone at 8500' altitude without suffering a migraine.
I used to think migraines were caused by altitude, caffeine, and stress. But most of the migraines had no explanation which didn't make sense. Now I think migraines are caused by low magnesium which in turn causes low serotonin. While not a total cure, taking magnesium has increased sleep quality, reduced the number of migraines, and vastly improved wellbeing. I have never felt so zen.