September 21, 2026
9 min read

Vitamin D and Cognitive Function: What Trials and Cohort Data Show

Low vitamin D levels appear consistently in people with cognitive decline and dementia. Here's what randomized trials and large cohort studies actually show — and where uncertainty remains.

Vitamin D and Cognitive Function: What Trials and Cohort Data Show. Stock photo via Pexels (Vintage  Laka).

A Quiet Pattern in Dementia Research

People diagnosed with Alzheimer's disease and other dementias are significantly more likely to have low 25-hydroxyvitamin D (25(OH)D) levels than cognitively healthy adults of the same age. That pattern has shown up across dozens of observational studies, in populations from Europe to North America to Asia. The question researchers have spent the last decade trying to answer is whether low vitamin D is a cause of cognitive decline, a consequence of it, or simply a marker that travels alongside other risk factors.

The answer, as of 2024, is not fully settled. But the weight of evidence has shifted enough that vitamin D and brain health is no longer a fringe association — it's a mainstream research question with large trials and long-term cohort data behind it.

What Observational Data Shows

A widely cited analysis using the UK Biobank — one of the largest prospective cohorts in the world — found that low vitamin D was associated with a significantly higher risk of dementia and stroke. The analysis, published in Nature Aging (2023) followed over 290,000 participants and estimated that around 17% of dementia cases might be preventable if vitamin D deficiency were eliminated. That figure comes with the usual caveats about observational data — confounding, reverse causation, and the difficulty of isolating any single nutrient — but the scale and methodology made it impossible to dismiss.

Earlier cohort work reached similar conclusions. The Cardiovascular Health Study, which tracked over 1,600 older adults in the United States, found that those with 25(OH)D levels below 20 ng/mL (below 50 nmol/L) had substantially elevated risk for cognitive impairment over a six-year follow-up, published in Archives of Internal Medicine (2010). A French cohort from the Three-City Study reinforced this, linking low vitamin D to faster cognitive decline in older women, published in JAMA Neurology (2012).

Across these studies, the threshold that keeps appearing as meaningful is around 20 ng/mL — the same level that marks clinical deficiency for bone and immune outcomes. People below that line consistently face higher risk for cognitive impairment in longitudinal follow-up.

Why the Brain Might Need Vitamin D

The biological case for a direct brain-vitamin D link is reasonably strong. Vitamin D receptors (VDRs) are expressed throughout the human brain, including in the hippocampus — the region most critical for memory formation. Vitamin D also influences the synthesis of neurotrophins like nerve growth factor (NGF), which supports neuronal survival, and modulates inflammatory pathways implicated in neurodegeneration.

A 2020 review in Ageing Research Reviews catalogued the proposed mechanisms: vitamin D's role in reducing amyloid-beta accumulation, regulating calcium homeostasis in neurons, and limiting neuroinflammation through modulating microglial activity. These aren't speculative pathways — they're observable in both cell studies and post-mortem brain tissue analyses.

What's less clear is whether supplementing to correct deficiency in adulthood can reverse or slow processes that have already begun. Most of these mechanisms are better studied at the cellular or animal level than in completed human trials.

What Randomized Trials Actually Show

Randomized controlled trials are where the picture becomes more complicated. The VITAL trial, which enrolled over 25,000 adults and tested 2,000 IU/day of vitamin D3 over five years, is the largest vitamin D supplementation trial completed to date. Its primary outcomes focused on cancer and cardiovascular events, but cognitive outcomes were assessed in a pre-specified substudy published in JAMA (2020). The result: no significant difference in global cognitive composite scores between the vitamin D group and placebo after two years of follow-up in the substudy.

That sounds like a null result, but there are important context points. The VITAL cognitive substudy participants had average baseline 25(OH)D levels around 30 ng/mL — not deficient. If vitamin D benefits cognition primarily in people who are genuinely low, a trial that enrolls mostly sufficient adults will likely show no effect, because there's no deficiency to correct.

A separate pre-specified secondary analysis of VITAL, published in EClinicalMedicine (2023), found that vitamin D3 supplementation reduced the risk of developing dementia by 40% — but this was in a subgroup analysis, not the primary outcome, and should be interpreted cautiously. Pre-specified secondary analyses are stronger than post-hoc analyses, but they still carry higher false-positive risk than a primary endpoint.

The D-HEALTH trial, conducted in Australia and published in American Journal of Clinical Nutrition (2020), tested monthly high-dose vitamin D3 (60,000 IU) versus placebo in older adults over three years. Cognitive outcomes showed no significant benefit. Again, participants were not selected for deficiency at baseline.

The Deficiency-First Hypothesis

The pattern across trials suggests that vitamin D supplementation may matter most when baseline levels are genuinely low — below 20 ng/mL — and that trials enrolling mostly sufficient adults are testing the wrong question. This is sometimes called the deficiency-first hypothesis: vitamin D isn't a cognitive enhancer for people who already have adequate levels, but correcting true deficiency may protect against accelerated decline.

A Mendelian randomization study published in BMJ Nutrition, Prevention & Health (2020) used genetic proxies for lifelong vitamin D levels to test causality more robustly than standard observational designs allow. It found evidence consistent with a causal protective effect of higher vitamin D on dementia risk, specifically at the lower end of the vitamin D distribution — supporting the idea that deficiency is where the action is.

Mendelian randomization isn't a randomized trial, but it largely sidesteps the reverse-causation problem that plagues observational data. When both observational evidence, mechanistic plausibility, and genetic proxy data all point in the same direction, the case for a real relationship becomes harder to dismiss — even without a clean trial in deficient populations.

Age as a Compounding Variable

Older adults are the population most affected by both vitamin D deficiency and cognitive decline — and also the group in whom the link looks strongest. Skin synthesis of vitamin D drops by roughly 75% between ages 20 and 70, because aging reduces epidermal concentrations of 7-dehydrocholesterol, the precursor that UVB converts into pre-vitamin D3. Reduced outdoor activity, institutionalization, and reduced dietary variety compound this further.

This is covered in more depth in the Rays guide on vitamin D deficiency risk after 65, but the relevance here is direct: an older adult who is already at higher dementia risk is also the person most likely to be genuinely deficient in vitamin D — making their cognitive outcomes more sensitive to whether that deficiency is detected and addressed.

Depression, Sleep, and Indirect Cognitive Effects

The relationship between vitamin D and cognition is also partly indirect. Low vitamin D has established associations with depressive symptoms, and depression is itself a risk factor for cognitive impairment and dementia. Similarly, vitamin D appears to influence sleep quality — poor sleep is one of the strongest modifiable risk factors for Alzheimer's pathology, through its role in amyloid clearance during deep sleep.

These pathways don't require vitamin D to act directly on neurons. If correcting deficiency reduces depressive symptoms or improves sleep duration, those downstream effects could translate into measurable cognitive benefits over time. The Rays post on vitamin D and sleep covers the sleep evidence in detail, and the post on vitamin D and depression reviews the randomized trial data on mood outcomes.

What This Means Practically

The evidence does not support taking high-dose vitamin D as a cognitive enhancer if your levels are already in the sufficient range (above 30 ng/mL). That question has been tested, and the answer is essentially null. What the evidence does support is treating vitamin D deficiency as a modifiable risk factor worth addressing — particularly in older adults, people who spend most of their time indoors, and people at higher baseline dementia risk.

For most adults, the practical step is knowing your 25(OH)D level. Testing twice yearly — once at the end of summer, once at the end of winter — gives a reliable picture of your range across seasons. A level below 20 ng/mL is clinically deficient by any standard definition, and correcting that through sun exposure, supplements (typically 2,000–4,000 IU/day of D3 for deficient adults), or both is supported by evidence across multiple health outcomes, cognitive trajectory included.

Sun exposure remains the most physiologically direct route when UVB is available. The catch is that UVB is seasonal and latitude-dependent, and the UV conditions that enable meaningful synthesis are narrower than most people assume. The Rays post on vitamin D and sun time variables breaks down what actually determines your sun window.

Key Takeaways

Low vitamin D (below 20 ng/mL) is consistently associated with higher dementia and cognitive impairment risk across observational studies and Mendelian randomization analyses. The biological pathways are plausible and well-documented at the mechanistic level, including VDR expression in the hippocampus, neurotrophic support, and neuroinflammation modulation.

Randomized trials testing supplementation in mostly vitamin D-sufficient adults have generally found no cognitive benefit — which is the expected result if deficiency is the key variable, not vitamin D level above the sufficient threshold. The large UK Biobank analysis and Mendelian randomization data both point toward deficiency as where the risk concentrates.

Indirect pathways through depression and sleep quality are also plausible routes by which vitamin D deficiency could affect cognitive trajectory over time. Older adults face compounding risk: reduced skin synthesis, lower activity levels, and higher baseline dementia risk all converge.

High-dose supplementation is not supported as a cognitive enhancer for people already at sufficient levels. The practical action is testing, then correcting deficiency if present — through a combination of sun exposure when UV conditions allow, and D3 supplementation in winter or at high latitudes.

What to do next

If you're not sure whether your current sun exposure is actually moving your vitamin D levels, use the Rays vitamin D calculator to estimate your synthesis window by location, season, and skin type. For ongoing tracking without manual logging, Rays automatically detects outdoor time and estimates daily vitamin D exposure across the year — so you can see whether your pattern is actually keeping you out of the deficiency range that the cognitive data flags as meaningful.