Supplements
Best Time to Take Magnesium: Morning or Night, Food and Medicines
The short answer
For most people there is no proven best hour: pick a time you will keep to every day. If you take magnesium for sleep, the main trial gave it 30 to 60 minutes before bed; if it loosens your stools, split the dose. The timing that really matters is spacing it from certain medicines, such as tetracycline and quinolone antibiotics and oral bisphosphonates.
For most people, the best time to take magnesium is the time you will actually remember every day. No study has shown that a morning dose is absorbed better or worse than an evening one, so taking it at the same time daily matters more than which hour you pick. Evening is the popular choice because sleep research gave magnesium shortly before bed. That is a sensible pattern if sleep is your reason for taking it. If a dose upsets your stomach or loosens your stools, take it with a meal or split it into two smaller doses.
The timing that really matters is the gap between magnesium and certain medicines. Magnesium can bind some antibiotics in the gut and lower the absorption of some bone-strengthening drugs, so they may not work as well as they should. Those gaps are measured in hours, and they matter far more than whether magnesium goes down with breakfast or at night.
Quick timing guide
Here is the short version for eight common situations. The sections below explain each one.
| Your situation | Timing to consider | Why |
|---|---|---|
| General top-up | Any consistent time; with a meal if it upsets your stomach | No trial shows one hour is better than another |
| Taking it for sleep | 30 to 60 minutes before bed | How the main 2025 sleep trial gave it |
| Loose stools | Split into two smaller doses | Unabsorbed magnesium draws water into the bowel |
| Tetracycline or quinolone antibiotic | Antibiotic at least 2 hours before or 4 to 6 hours after magnesium | Magnesium binds these drugs in the gut |
| Oral bisphosphonate for bone health | At least 2 hours apart | Magnesium lowers absorption of the drug |
| Gabapentin | Ask whether to keep magnesium 2 hours before it, as advised for antacids | Antacids, many containing magnesium, need that gap |
| Levothyroxine | Ask your pharmacist; minerals such as calcium and iron need 4 hours | The medicine is sensitive to minerals and antacids |
| Magnesium citrate as a laxative | Other medicines at least 2 hours before or after | Label advice for the laxative product |
Morning or night?
On the question of magnesium morning or night, the honest answer is that the research has not settled it. The NIH Office of Dietary Supplements (ODS) magnesium fact sheet, our main reference for magnesium, says nothing to suggest that clock time changes absorption. We found no trials comparing a morning dose with an evening dose.
What does exist is sleep research that happened to give magnesium at night. The clearest example is a 2025 randomized, placebo-controlled trial of magnesium bisglycinate published in Nature and Science of Sleep. It included 155 healthy adults who reported poor sleep. They took 250 mg of magnesium a day, 30 to 60 minutes before bed, for four weeks. Their insomnia scores improved a little more than with a placebo (a dummy pill): a small but measurable effect.
A 2021 systematic review and meta-analysis in BMC Complementary Medicine and Therapies pooled three small trials in older adults. People fell asleep about 17 minutes sooner with magnesium, but the reviewers rated that evidence low quality.
So if sleep is the goal, magnesium before bed matches the way it has been studied. If you take it to fill a gap in your diet, morning works just as well and may be easier to remember alongside breakfast.
With food or on an empty stomach?
There is little direct research on taking a magnesium supplement with or without food. Still, a meal is a natural way to soften stomach upset from any supplement, and a habit tied to a meal tends to stick.
If you use liquid magnesium citrate as a laxative, MedlinePlus says to take it with a full glass of liquid, about 240 ml (about 8 fl oz).
The bigger point is your other medicines. If you take something that must be swallowed on an empty stomach, such as levothyroxine, plan the magnesium dose around that medicine, not the other way around.
Splitting the dose
ODS explains that high doses of magnesium from supplements cause diarrhea because the part your body does not absorb holds water in the gut. A 2021 systematic review in Nutrition found that the share of magnesium absorbed depends on the dose.
Both points support the same habit. As an example, if 300 mg in one go loosens your stools, two doses of 150 mg may not. Keep the daily total within the adult upper limit of 350 mg, which covers magnesium from supplements and medicines combined (not food), unless a clinician advises otherwise.
Magnesium alongside other minerals and supplements
- Zinc: ODS reports that one study found very high zinc intake, 142 mg a day from supplements, interfered with magnesium absorption and upset the body’s magnesium balance. That is a very large dose, so this matters most if you take a high-strength zinc product.
- Multivitamins and antacids: many contain magnesium. Add everything up, because the 350 mg upper limit applies to the total from supplements and medicines.
- Vitamin D: vitamin D is best absorbed with a meal that contains some fat, and our page on when to take vitamin D explains why. If you take both, taking them together at a meal is a simple routine.
Medicines that need a gap
- Tetracycline and quinolone antibiotics: magnesium binds drugs such as doxycycline, ciprofloxacin and levofloxacin in the gut, which can reduce how much reaches your blood. ODS advises taking the antibiotic at least 2 hours before, or 4 to 6 hours after, a magnesium supplement. Ask your pharmacist about any other antibiotic.
- Oral bisphosphonates: these are bone drugs such as alendronate. Magnesium-rich supplements can reduce how well they are absorbed, and ODS suggests keeping them at least 2 hours apart.
- Gabapentin: MedlinePlus advises taking antacids at least 2 hours before gabapentin. Many antacids contain magnesium, so ask your pharmacist whether the same gap applies to your supplement.
- Levothyroxine (thyroid medicine): MedlinePlus lists antacids among the products that interact with it and asks for a 4-hour gap from calcium carbonate and iron supplements. Ask your pharmacist how far to keep magnesium from your thyroid dose.
Signs your routine needs adjusting
- Loose stools or cramping: split the dose, take it with meals, or step down the amount. If it continues, try a different form; our magnesium glycinate vs citrate comparison explains which forms are gentler on the gut.
- Stomach upset without loose stools: move the dose to the middle of a meal.
- Forgetting doses: link the dose to something you never skip, such as brushing your teeth at night or eating your first meal.
- A new prescription: ask the pharmacist whether it needs spacing from magnesium before you take the two together.
- Switching products: recheck the elemental magnesium per serving (the amount of actual magnesium, not the whole compound). The same number of capsules can deliver a different dose.
Three example routines
These show how the spacing rules can fit into a day; they are illustrations, not personal advice, and a pharmacist can adjust them to your exact prescriptions.
- Magnesium for sleep, no other medicines: one dose 30 to 60 minutes before bed, the pattern used in the 2025 sleep trial. If your stools loosen, move half the dose to dinner.
- A two-week course of doxycycline: ask your pharmacist whether pausing magnesium for a short course makes sense. If you keep taking it, leave at least 4 to 6 hours after the antibiotic before your magnesium dose. For example, take the antibiotic at 8 a.m. and magnesium with dinner.
- Levothyroxine on waking: MedlinePlus says levothyroxine is usually taken on an empty stomach, 30 minutes to 1 hour before breakfast. Take magnesium later in the day, with the exact gap agreed with your pharmacist, since MedlinePlus asks for 4 hours between levothyroxine and minerals such as calcium and iron.
If you miss a magnesium dose, simply take the next one at the usual time. There is no need to double up, and doubling could push you past the daily upper limit.
Medicines that change your magnesium level
Some medicines do not clash with a dose but change how much magnesium your body keeps. ODS notes that loop and thiazide diuretics (water pills) increase magnesium loss in urine, while potassium-sparing diuretics reduce it.
Proton pump inhibitors, medicines that lower stomach acid, can cause low blood magnesium when taken for more than about a year. In about a quarter of the cases the FDA reviewed, supplements did not correct it and the medicine had to be stopped. If you take any of these, decide on magnesium with your prescriber rather than on your own.
To work out how much you need, see our magnesium dosage and upper limit page or use the nutrient RDA lookup. To choose a form, the glycinate vs citrate comparison above is a good place to start.
Who should be careful
- People with kidney disease: reduced kidney function raises the risk of magnesium building up to toxic levels. Talk to your doctor before taking any.
- Anyone on the medicines above: if you take tetracycline or quinolone antibiotics, bone drugs, thyroid medicine or gabapentin, agree a timing plan with a pharmacist.
- People taking diuretics or long-term proton pump inhibitors: your magnesium needs can move in either direction, so check with your prescriber.
- Older adults taking several medicines: ODS notes they are more likely to have conditions or prescriptions that change magnesium status. A medicines review with a pharmacist is worth asking for.
- People who are pregnant or breastfeeding: the recommended intake is different. Check it in the dosage guide and with a clinician before adding a supplement.
Questions
- Is it better to take magnesium in the morning or at night?
- Research has not shown that the clock changes how much magnesium you absorb. Evening dosing is popular because sleep trials gave magnesium 30 to 60 minutes before bed, and that is a reasonable choice if sleep is your reason. If mornings suit your routine better, take it then. Taking it at the same time each day matters more than which time you choose.
- Should magnesium be taken with food?
- There is little direct research on food and magnesium supplements. Taking a dose with a meal is a simple way to try if a supplement upsets your stomach, and it also makes the habit easier to remember. If you take a medicine that must be swallowed on an empty stomach, such as levothyroxine, plan magnesium around that medicine rather than the other way round.
- How long should I wait between magnesium and antibiotics?
- For tetracycline antibiotics such as doxycycline and quinolones such as ciprofloxacin, the NIH Office of Dietary Supplements advises taking the antibiotic at least 2 hours before, or 4 to 6 hours after, a magnesium supplement. Magnesium binds these drugs in the gut and can reduce how much reaches your blood. Ask your pharmacist about any other antibiotic.
- Can I take magnesium with zinc, calcium or vitamin D?
- The clearest documented mineral clash is with very high zinc: one study found 142 mg of zinc a day interfered with magnesium absorption and balance. Ordinary combinations are widely used, but if a multivitamin and a separate magnesium both contain magnesium, add them together. The 350 mg adult limit covers all supplement and medicine sources combined.
- Can I split my magnesium dose?
- Yes. Splitting a daily amount into two smaller doses is a practical way to reduce loose stools, because unabsorbed magnesium is what draws water into the bowel, and the share absorbed depends on the dose. Keep the total within 350 mg a day from supplements unless a clinician advises otherwise.
Sources
- Magnesium: Fact Sheet for Health Professionals, NIH Office of Dietary Supplements. Accessed October 26, 2026
- Magnesium Citrate, MedlinePlus, U.S. National Library of Medicine. Accessed October 26, 2026
- Gabapentin, MedlinePlus, U.S. National Library of Medicine. Accessed October 26, 2026
- Levothyroxine, MedlinePlus, U.S. National Library of Medicine. Accessed October 26, 2026
- Magnesium Bisglycinate Supplementation in Healthy Adults Reporting Poor Sleep: A Randomized, Placebo-Controlled Trial (Nature and Science of Sleep, 2025), PubMed Central. Accessed October 26, 2026
- Oral magnesium supplementation for insomnia in older adults: a Systematic Review and Meta-Analysis (BMC Complementary Medicine and Therapies, 2021), PubMed Central. Accessed October 26, 2026
- Bioavailability of magnesium food supplements: A systematic review (Nutrition, 2021), Elsevier. Accessed October 26, 2026