Dietary Magnesium and Migraine in Adults

A Cross-sectional Analysis of the National Health and Nutrition Examination Survey 2001-2004

Margaret Slavin PhD, RDN; Huilun Li MS; Manisha Khatri BPS; Cara Frankenfeld PhD


Headache. 2021;61(2):276-286. 

In This Article

Subjects and Methods

Study Design

This analysis included cross-sectional data from the NHANES. NHANES is a continuous, nationally representative survey designed to assess the health and nutritional status of civilian, non-institutionalized adults and children in the United States, conducted by the U.S. National Centers for Health Statistics (NCHS) within the Centers for Disease Control and Prevention.[14] The dietary intake component of NHANES is known as What We Eat in America and is conducted by the Agricultural Research Service of the U.S. Department of Agriculture (USDA) in collaboration with the U.S. Department of Health and Human Services.[14] During each 2-year cycle, approximately 10,000 Americans are recruited to participate in NHANES via a combination of a physical examination in Mobile Examination Centers (MEC) and home interviews.[14] The NCHS Research Ethics Review Board/Institutional Review Board approved the NHANES protocols and obtained written informed consent from participants.[14] As this study analyzed de-identified public use NHANES data (, it was exempt from further review by the local Institutional Review Board.[14]

The sample size was based on the available data; no a priori statistical power calculation was conducted. This study included 2001–2004 NHANES data where migraine and dietary intake data were collected using consistent methodology. Migraine data were collected between 1999 and 2004, but the dietary intake assessment method changed between the 1999–2000 and 2001–2002 cycles, complicating direct comparisons of dietary nutrient intake data across those cycles.[15]


Participants included adults ages 20- to 50-years old, as reported on the Demographic Questionnaire. This age range was selected to include the years of life with the highest prevalence and burden of migraine.[1] Individuals who reported pregnancy, breastfeeding, or menopause on the Reproductive Health Questionnaire, or with a positive urine pregnancy test were excluded. Any individuals whose Alcohol Use Questionnaire reflected greater than 150 drinks per month were also excluded for potential heavy alcohol use. Participants whose dietary interviews showed consumption of less than 500 calories or greater than 5000 calories per day were excluded for unrealistic dietary intake. Also, participants with missing data for dietary intake, alcohol intake, gender, body mass index (BMI), migraine status, and poverty income ratio (PIR) were excluded.

Migraine Assessment

Migraine status was determined according to each participant's answer to the NHANES Miscellaneous Pain Questionnaire, which asked all participants 20 years of age or older "During the past 3 months, did you have severe headaches or migraines?" Participants who answered "Yes" were categorized as having migraine, whereas those who answered "No" were included in the control group. This categorization does not enable verification of diagnoses against the International Classification of Headache Disorders (ICHD) diagnostic criteria; however, it has been used in prior expert analyses[7,16] on the basis of the American Migraine Prevalence and Prevention study, which evidenced that most individuals who reported severe headache met ICHD-II criteria for migraine or probable migraine.[17]

Magnesium Intake Assessment

This study assessed both "dietary" and "total" intake of magnesium, where dietary intake was contributed by foods and beverages, and total intake included magnesium from dietary supplements in addition to food and beverages. Dietary intake in NHANES is assessed by an in-person 24-hour dietary recall interview collected at the MEC via the validated, five-step USDA Automated Multiple Pass Method in combination with food composition data[18–20] in the USDA Food and Nutrient Database for Dietary Studies.[21] Dietary intake data for magnesium (mg/day) were retrieved from the NHANES Dietary Interview—Total Nutrient Intakes data file.

Dietary supplement intake in NHANES is assessed during the home interview, where information is collected about the use of vitamin, mineral, herbal, and other dietary supplements. Participants who report taking any dietary supplements are asked to show the interviewer the containers to enhance accuracy, then answer questions about the dose of supplement they take, how frequently, and for what duration they have taken each supplement. Data were retrieved and calculated by combining the Dietary Supplement Use 30-day Files 1 and 2, Dietary Supplement Product Information, and Dietary Supplement Ingredient Information files. The dietary supplement dataset includes magnesium intake from non-prescription antacids, regardless of whether the antacids were reported on the dietary supplement or medication use questionnaires. For the purposes of the present analysis, only individuals meeting the aforementioned inclusion/exclusion criteria who consumed a supplement that contained any form of magnesium were considered as a supplement user; supplements containing magnesium were identified according to their Ingredient ID. For supplements, which reported doses as the amount of magnesium salt, the amount of elemental magnesium contributed by each magnesium salt was calculated according to the percent of molecular weight contributed by magnesium (i.e., magnesium carbonate consists of 28.9% elemental magnesium). If individuals were consuming multiple sources of magnesium through supplements, the magnesium from all supplement sources was summed for each individual. The average daily supplemental magnesium intake for each individual was calculated by dividing the sum of supplemental magnesium intake in the past 30 days by 30.

The total daily magnesium intake was calculated by summing the dietary intake and supplemental intake. For individuals with no supplemental magnesium intake or with missing supplement data, their total magnesium intake was equivalent to their dietary magnesium intake.

Participants' magnesium consumption levels were assessed for attainment of their gender and age-specific recommended dietary allowances (RDAs): males 19–30 y/o—400 mg/day; males 31–50 y/o—420 mg/day; females 19–30 y/o—310 mg/day; females 31–50 y/o—320 mg/day.[22]

Statistical Analysis

For the purpose of this analysis, magnesium dietary intake data were heavily right skewed; therefore, the data were divided into quartiles (Qs) with empirical cutoffs for the primary analysis.

Summary statistics are reported as sample-weighted frequencies and percent distributions. The full sample 2-year MEC exam weight was applied to all statistical analyses (both summary and inferential statistics) in this study according to NHANES analytical guidance.[23] Demographic comparisons between migraine group and controls were performed using an independent samples t-test of the mean for age and Chi-square (χ 2) tests across groups for gender, BMI, alcohol intake, and PIR. Prior to analysis, BMI, alcohol intake, and PIR data were categorized into ordinal groups as described above to minimize the influence of outliers.

Covariates were identified a priori based on their association with migraine in the prior literature, and included gender,[24–26] alcohol intake,[27–29] weight status,[30,31] and socioeconomic status determined by annual household income,[32] and all covariates stayed in the final logistic regression models. Alcohol consumption in drinks per month was calculated and categorized as <1 drink per month, 1–19 drinks per month, and ≥20 drinks per month. BMI was also categorized by World Health Organization Standards as underweight (<18.5 kg/m2), normal weight (18.5–24.9 kg/m2), overweight (25.0–29.9 kg/m2), and obese (≥30.0 kg/m2).[33] PIR, which divides family income by the poverty threshold, was used as an indicator of socioeconomic status in categories of <1, 1 to <2, 2 to <3, 3 to <4, and ≥4. A PIR value of 0 corresponds to no income, a value of 1 corresponds to a family income at 100% of the federal poverty level (FPL), and values above 1 correspond to multiples of the FPL.

Logistic regression was used to compute odds ratios (ORs) and 95% confidence intervals (CIs) for migraine, comparing each magnesium intake group to the lowest intake group as the reference; analysis was conducted in the whole sample and stratified by gender. The P-trend was calculated via median logistic regression and adjusted for potential confounders. A test for interaction was conducted using an interaction term between gender and the median Qs values in logistic regression. For all statistical tests used in this study, two-tailed testing was performed and a p value less than 0.05 was defined as statistically significant. Analyses were conducted using Stata/IC 15.1 (StataCorp, College Station, TX, USA).[34]