Is It Safe To Take Magnesium And Melatonin Together?

In our latest question and answer, the pharmacist discusses whether or not it is safe to combine magnesium and melatonin.

2 min read Updated Jun 2026 Read by 9,509 people
Is It Safe To Take Magnesium And Melatonin Together?
Share
Joe asked

Is it safe to take melatonin and magnesium together?

Jul 19, 2022
The quick answer
  • There are no known interactions between magnesium and melatonin, so they can safely be taken together.
  • Studies show that taking magnesium and melatonin together may help improve sleep better than taking either one alone.
  • Magnesium supplementation can increase melatonin levels in the body, which may be one reason why the combination is effective for sleep.
A quick summary of Dr. Brian Staiger, PharmD's full answer below, condensed by AI from that answer only (not from any outside source). The pharmacist's answer is the source of record.

Answer

Thanks for reaching out to us Joe!

There are no known interactions between magnesium and melatonin. They can safely be taken together.

In fact, there are a number of products on the market that contain both magnesium and melatonin as several studies have reported that the combination can help improve sleep compared to either alone. These studies have also reported that magnesium supplementation increases melatonin levels (which is one reason why magnesium may help improve sleep).

What Do The Studies Say?

As mentioned, several studies have shown positive benefits for the treatment of insomnia using melatonin and magnesium.

Magnesium supplementation in some individuals seems to raise melatonin levels, and studies in which individuals supplemented with both showed improved sleep metrics.

One such study reported the following regarding magnesium supplementation:

As compared to the placebo group, in the experimental group, dietary magnesium supplementation brought about statistically significant increases in sleep time, sleep efficiency, concentration of serum renin, and melatonin, and also resulted in significant decrease of ISI score, sleep onset latency and serum cortisol concentration.
J Res Med Sci . 2012 Dec;17(12):1161-9

Another study, testing a combination of zinc, magnesium, and melatonin, reported the following results:

The administration of nightly melatonin, magnesium, and zinc appears to improve the quality of sleep and the quality of life in long-term care facility residents with primary insomnia.
J Am Geriatr Soc . 2011 Jan;59(1):82-90

Now, larger-scale studies are needed to better understand where melatonin and magnesium supplementation could fit in for the treatment of insomnia, but, going back to your question, there is no evidence to suggest they interact or interfere with one another.

Final Words

Thanks again for reaching out and please feel free to do so again in the future!

References & sources
  1. The effect of magnesium supplementation on primary insomnia in elderly: A double-blind placebo-controlled clinical trial — PubMed
  2. The effect of melatonin, magnesium, and zinc on primary insomnia in long-term care facility residents in Italy: a double-blind, placebo-controlled clinical trial — PubMed
  3. Effects of Melatonin and/or Magnesium Supplementation on Biomarkers of Inflammation and Oxidative Stress in Women with Polycystic Ovary Syndrome: a Randomized, Double-Blind, Placebo-Controlled Trial — PubMed
Glossary — Terms in This Answer
Melatonin
A hormone your body naturally produces to help regulate sleep and wake cycles.
Magnesium
A mineral that plays a role in many body functions, including muscle relaxation and sleep regulation.
Insomnia
A sleep disorder characterized by difficulty falling asleep or staying asleep.
Supplementation
The practice of taking additional amounts of a nutrient or substance beyond what you get from food.
Sleep efficiency
The percentage of time you spend in bed that you actually spend sleeping.
Sleep onset latency
The amount of time it takes to fall asleep after getting into bed.
Serum cortisol
The amount of cortisol, a stress hormone, present in your blood.
ISI score
A numerical measurement used to assess the severity of insomnia symptoms.
Did this answer your question?
Dr. Brian Staiger, PharmD
About the pharmacist

Dr. Brian Staiger, PharmD

Clinical Pharmacy

Doctor of Pharmacy, board certified clinical pharmacist (BCPS), American Herbalist Guild, Medication Therapy Management certified

Brian Staiger, PharmD, BCPS, is a licensed pharmacist with more than 13 years of experience across retail pharmacy, clinical pharmacy, medication safety, pharmacy program development, and healthcare administration. He is the founder of HelloPharmacist.com, where he helps patients...

More answers from Brian →
Ask a Pharmacist