Why does magnesium help some people sleep and do nothing for others?

Start your free 7-night trial

If you have taken magnesium for sleep and it did nothing, you are not imagining it and you probably did not take it wrong. Magnesium is aimed at the body. For a lot of people lying awake at night, the thing holding sleep open is not in the body. It is a mind that has learned to stay switched on, and a mineral was never going to change that.

The short answer

Magnesium may help where sleep is being disrupted by something physical. Where sleep is being held open by a mind that will not stop working, magnesium is not the variable in the equation. Sleep researchers call that state cognitive hyperarousal, and it is one of the most consistent findings in people living with chronic insomnia. That is not a knock on magnesium. It is a mismatch between the fix and the cause.

What is everyone actually buying?

Look at what people are searching for and the pattern is hard to miss.

Magnesium glycinate is now a term with roughly a million searches a month, up 22 per cent year on year. Magnesium supplement sits at 673,000 a month, up 235 per cent. Magnesium glycinate for sleep, 550,000, up 174 per cent. The Oura ring is on about 1.5 million a month. Sleep hygiene holds 135,000. Brown noise, 90,500. These figures come from the Rising Trends database, refreshed in July 2026, which aggregates search and social signal rather than pulling raw Google exports, so read them as direction and scale rather than exact counts.

Every one of those is aimed at the body or the bedroom. Minerals, temperature, sound, tracking, light. All reasonable things to try. None of them touch what is holding the switch open for a lot of people with long-running sleep trouble.

That is the gap. People are spending real money on external objects to change an internal state, and almost nobody is talking about the pattern underneath the state.

What is cognitive hyperarousal, in plain words?

It is the brain staying in an alert, problem-solving state at the exact moment the body is ready to sleep. It is not the same as being an anxious person in general. Plenty of people who describe themselves as calm lie there at midnight running tomorrow's conversation on a loop. About 1 in 10 adults lives with chronic insomnia, and for many of them this is a big part of what keeps it going.

Part of why bedtime is where it shows up is simple. Bed is often the first quiet moment of the day. No phone, no kids, no task in front of you. Thoughts do not get louder at night, they just stop competing with anything.

Then there is the learned bit, which matters more than the name. Enough bad nights and the brain starts to associate bed with frustration and effort. So the approach of bedtime itself begins to raise alertness rather than lower it. You are not winding down, you are getting ready for a fight you have had a hundred times. The bed becomes a cue for vigilance.

The American Academy of Sleep Medicine makes a related point that catches most people out. Trying to force sleep and trying to suppress thinking both tend to make the whole thing worse, because effort is the opposite of what the system is waiting for.

If any of that sounds like your night, we unlock a sleep session free for seven nights, no credit card, and there is a link at the end. Read the rest first.

What does Rob Edmonds say is running underneath?

Rob Edmonds created Cognitive Pattern Reprogramming and wrote the book it takes its name from, The MindShift Method: Cognitive Pattern Reprogramming. He holds diplomas in Clinical Hypnosis and Strategic Psychotherapy and is a Neuro-Linguistic Programming Master Practitioner, and is a member of the International Strategic Psychotherapists Association and the Australian Society of Clinical Hypnotherapists. Rob practises in New South Wales, Australia. He has been describing this loop for years, and his framing is worth having.

In episode 4 of the MindShift podcast, Why Your Brain Won't Switch Off At Night, he names four drivers sitting under a mind that will not disengage.

  • Internal orientation. Attention pulled constantly inward, into your own thoughts and interpretations, until inside your head becomes the default place to be.
  • Hyperarousal. The system running at a higher level of activation than the moment needs. Slightly on edge, slightly elevated, slightly heightened. As Rob puts it, that is not chosen. It is automatic, it is learned, and it is reinforced over time.
  • Low tolerance for ambiguity. Discomfort with not knowing, so the mind tries to manufacture its own certainty by replaying and rehearsing until something feels resolved.
  • Ineffective compartmentalisation. Work thoughts arriving in personal time, past experiences replaying into current ones, everything blending together.

His line about the whole thing is the clearest summary of the problem we have found. "It's like trying to quiet the noise without turning off what's creating the noise."

And in his essay When Sleep is Not Resolving Your Exhaustion, he describes a nervous system with two basic settings, one that says it is safe to rest and repair, and one that says stay alert. Under sustained pressure, alertness becomes the default and keeps running even while you are unconscious. Which is why the eight hours can go by and the tiredness stays put.

The sentence in that essay most people underline is this one. "Pushing harder at something your nervous system controls automatically tends to backfire, because effort itself can read as more alertness."

Does the time you wake up tell you anything?

Often, yes. Waking in the early hours and being unable to get back down is a distinct pattern from struggling to fall asleep in the first place, and it is frequently linked to the normal early-morning rise in cortisol becoming exaggerated under long-running stress.

If that is your version, there is more on it across the rest of the Sleep & Recovery writing, and Back to Sleep After Waking, further down, is the session built for the early hours.

If it is a learned pattern, can it be worked with?

That is the whole argument for doing it this way. A learned pattern is not a fixed trait. Rob's line on it is short. "If it was learned, it can be unlearned."

Cognitive Pattern Reprogramming, or CPR, is designed to help at that level rather than at the level of the thoughts themselves. It is audio, 15 to 20 minutes, listened to daily and usually at bedtime, and repetition over roughly 21 days is what the programs are built around. It is not a relaxation track and it is not a lecture. It is designed to give the nervous system a different set of cues about what night time is for. Many people find the change shows up as less effort at bedtime rather than as a dramatic moment. Results vary.

Which session depends on what your night actually looks like.

  • Quiet the Nighttime Mind, for the one that will not stop talking once the light goes out.
  • The High Impact Off Switch, for the person still working in their head at 11pm.
  • Back to Sleep After Waking, for the early hours.
  • Sleep After Stressful Days, for when the day is the problem.
  • Nervous System Downshift for Sleep, for the body that will not settle.
  • Deep Restful Sleep, for sleep that happens but does not restore anything.

Your free trial opens Sleep After Stressful Days for seven nights. The rest unlock with a subscription.

So should you throw out the magnesium?

No. If it helps you, keep taking it, and take any questions about it to your GP or pharmacist. The point of this article is not that supplements are useless. It is that a fix aimed at the body may do very little to a pattern that is running in the mind, and knowing which one you are dealing with saves you a lot of money and a lot of nights.

Cognitive Pattern Reprogramming works alongside medical and psychological care, never instead of it. If sleep has been a problem for months, if you are managing a diagnosed condition, or if something feels worse than tired, please talk to your doctor first.

Where to start tonight

Three things, none of which cost anything.

  1. Stop doing the maths. Counting the hours you have left is the brain looking for certainty it cannot get, and it raises alertness every time.
  2. Stop trying to sleep. Effort reads as alertness. Lying there willing it to happen is still work.
  3. Change the question. Not how do I stop thinking, but what is keeping my mind switched on. That is the one Rob puts at the centre of episode 4, and it is the one that leads somewhere.

Then, if you want something running underneath while you do it, that is what the sleep programs are for.

Frequently Asked Questions

For some people it may help, particularly where sleep is being disrupted by something physical. For a lot of others it does very little, because the thing holding their sleep open is a mind that will not stop working rather than anything in the body. Both can be true at once. Any question about taking it, or about how much, belongs with your GP or pharmacist.

It is the brain staying in an alert, problem-solving state at the point the body is ready to sleep. Sleep researchers consistently find it in people living with chronic insomnia. It is not the same thing as being an anxious person in general, which is why plenty of people who feel calm during the day still cannot settle at night.

Falling asleep and staying asleep are two different patterns. Early hours waking is often linked to the normal early-morning rise in cortisol becoming exaggerated under long-running stress. The waking itself is normal. What keeps you awake is usually what the mind does in the seconds after it.

A learned pattern can shift, and that is what Cognitive Pattern Reprogramming is designed to help with. It works alongside anything you have been prescribed, not instead of it, and no decision about medication should be made without the doctor who prescribed it.

The programs are built around daily listening, 15 to 20 minutes, with repetition over roughly 21 days being what the design is based on. Many people find the first thing they notice is less effort at bedtime rather than a dramatic change. Results vary and there are no guarantees on timing.

Yes, if it has been going on for months, if you are managing a diagnosed condition, or if something feels worse than tired. Cognitive Pattern Reprogramming works alongside medical and psychological care, never instead of it.