Mushrooms are the only produce-aisle food that makes vitamin D, and commercial ones are grown in darkness so they carry almost none. Sunlight can increase mushroom vitamin D, but a change in the food does not guarantee the same change in a blood test. Compare the exposure conditions, serving units, and human trial results before relying on mushrooms to meet a vitamin D need.

Mushrooms make vitamin D under ultraviolet light, and the ones in the shop were grown in the dark.

That single fact separates a true claim about the food from a much shakier claim about the person eating it, and most coverage runs the two together.

Why the ones you buy have almost none

Mushrooms are the only thing in the produce aisle that can make vitamin D at all. That part of the headline is correct and worth keeping.

The catch is in how the vitamin gets made.

The precursorErgosterol, which sits in the mushroom already
The triggerUltraviolet light, which converts it to vitamin D2
How commercial mushrooms are grownIn darkness, in climate-controlled rooms
What that leaves in the punnetA token amount rather than a useful one
When the conversion can still happenAfter harvest, which is what makes any of this practical

The punnet below holds plenty of ergosterol and has never met any ultraviolet light.

A loose pile of fresh whole white button mushrooms on a plain pale kitchen counter
These were grown in the dark, which is why the vitamin D figure on them is close to zero.

The mushroom has the raw material and no light.

Nothing about the growing method is a mistake, since darkness suits the crop, but it does mean the vitamin D headline arrives at the shop unfulfilled. Some producers now run harvested mushrooms under ultraviolet lamps and label them as such.

  • A pack claiming a vitamin D figure has almost certainly been treated
  • A pack with no such claim almost certainly has not
  • The two sit side by side in the same chiller and look identical
  • Treated mushrooms cost more, which is the only other clue on the shelf

What ultraviolet actually does

The conversion is a single photochemical step, which is why it is quick and why it stops at the surface.

Extreme close view of the underside of a mature white mushroom showing dense dark brown radiating gills
Gills carry the most ergosterol and the most surface area, which is why they face the light.

Five details govern everything that follows.

The molecule
Ergosterol, spread through the mushroom and concentrated toward the gills
The wavelength
Ultraviolet B, the same band that makes vitamin D in skin
The timescale
Minutes rather than hours
The limit
Only surfaces the light reaches convert, so exposed area governs the yield
Living or not
Irrelevant, which is why a sliced mushroom works as well as a whole one

Exposed area is the part that turns into practical instructions. A whole mushroom presents its cap to the light and hides everything else, while a sliced one presents several times as much.

The gilled underside is the surface that matters most, because it holds both the highest ergosterol concentration and by far the largest area.

Putting them in the sun yourself

This works, and it has been measured rather than merely recommended.

Sliced white mushrooms laid gill side up in a single layer on a wire tray outdoors in bright direct sunlight
Sliced, gill side up, single layer, direct sun. Each of those four words is doing work.

The numbers behind that arrangement are worth quoting exactly.

After 15 minutes100 grams of sliced button mushrooms in midday midsummer sun reached 17.5 micrograms of vitamin D2
After 60 minutesThe same mushrooms reached 32.5 micrograms
The arrangementSliced, gill side up, in a single layer, in direct sun
Through a windowMuch weaker, because ordinary glass blocks most ultraviolet B

Those figures are a best case rather than a typical afternoon. Midday, midsummer sun is the strongest ultraviolet most people ever stand in, and the same tray in October at a northern latitude is a different experiment.

Two identical trays of sliced mushrooms side by side, the left in bright direct sunlight and the right in deep shade
Shade is not a slower version of sun here, because the wavelength that does the work barely reaches it.

The window point catches people out most often, because a sunny windowsill feels like the obvious place and ordinary glass removes most of the wavelength that does the work.

  • Slice them first, since exposed area is what converts
  • Lay them gill side up in one layer, not heaped
  • Use direct outdoor sun near the middle of the day
  • Expect much less outside high summer, and much less at high latitudes

If you are going to leave them out anyway, drying them at the same time is the obvious move, and drying mushrooms has its own conditions worth getting right.

For anything you are not drying, the sun session ends and normal rules resume, so storing fresh mushrooms picks up from there.

Does eating them change your blood level?

Here the ground gets less firm, and the honest answer has two halves that do not fully agree. The food side is settled, because ultraviolet light puts real, measurable vitamin D2 into a mushroom, and eating that mushroom puts real, measurable vitamin D2 into blood.

Neither of those results is wrong, and reading only one of them produces a confident answer that the evidence does not support.

Warning

A non-significant pooled result is not proof that mushrooms do nothing. It means six trials did not agree well enough to settle the question, and anyone treating a diagnosed deficiency should be working from blood tests and their own clinician rather than from any food page.

Why D2 is not simply D3

There is a mechanism behind that disagreement, and it is worth knowing because it explains why two honest sources can differ.

Mushrooms make vitamin D2, while sunlight on skin and animal foods make vitamin D3, and several reviews find D3 the more effective of the two at raising total vitamin D status. The more interesting finding is what happens to the two together.

Note

In half of the trials covered by the 2023 review, the vitamin D3 fraction in blood fell while the D2 fraction rose. That is why a mushroom can add vitamin D to a meal without a person's total moving as much as the food figure suggests.

The question is genuinely open rather than closed against mushrooms. A separate trial not included in that review found mushroom D2 as effective as both D2 and D3 supplements at the same daily dose.

It is worth naming who is arguing which side. The 2024 review making the strongest case for mushrooms as a public vitamin D solution was funded by a horticulture industry body, and most of its authors were employed by a food consultancy, which is disclosed in the paper and does not by itself make the case wrong.

Which species, and how much

Species matters less than exposure, but it is not irrelevant, and the units matter more than either.

A portion of sliced white mushrooms sitting on the platform of a small digital kitchen scale
Every figure here is per 100 grams, which is a generous portion rather than a token one.

Four species cover almost everything a reader will meet.

MushroomNotes
White button, cremini, portabellaThe same species at three ages, and the one most of the measurements used
OysterMeasured under lamps and responds strongly
EnokiThe strongest responder in one lamp study, on a dried weight basis
ShiitakeTraditionally sun dried, which is the oldest version of this whole idea

Most of the published human work used button mushrooms, so cremini and button sit closest to the evidence rather than furthest from it.

That same lamp work covered the oyster mushroom, which converts readily. Its thin flesh and very large gill area are mostly exposed surface, which is what the lamps reward.

Warning

Lamp studies often report micrograms per 100 grams of dried weight, and dried mushroom is a small fraction of its fresh weight. Comparing a dried figure with a fresh one overstates the food several times over, and headline numbers in the thousands are almost always dried weight.

Sun drying has been doing this quietly for centuries. Dried shiitake caps prepared in sunlight rather than a dehydrator picks up vitamin D2 as a side effect of the drying.

Where this sits against other sources

Mushrooms are a real contributor and a poor sole strategy, and both halves of that deserve saying plainly.

SourceWhat it gives youThe catch
Summer sun on skinVitamin D3, in quantities food rarely matchesSeason, latitude, skin, and the risks of deliberate exposure
Supplements and fortified foodA known dose, stated on the labelRequires knowing what dose you need
UV-treated mushrooms, labeledA meaningful amount of D2, stated on the packSold in fewer shops, and easy to confuse with untreated ones
Untreated mushroomsAlmost nothingStill a food worth eating, just not for this
Home sun exposureLarge gains, measured under good conditionsHighly variable, and no way to know what you actually got

The variability is the honest limit, because a supplement tells you what you took and a tray on a balcony does not.

  • Mushrooms suit topping up a reasonable diet
  • They do not suit correcting a shortfall someone has been diagnosed with
  • Untreated mushrooms contribute nothing measurable to this
  • Nothing on this page replaces a blood test or a clinician

Anyone who reads this and concludes they would rather take something measurable is drawing a sensible conclusion, and choosing a supplement is a different problem with its own pitfalls.

One boundary is worth marking before finishing. This is a nutrient question rather than a therapeutic one, and the claims attached to medicinal fungi are a separate subject with a separate evidence base.

Sources & References

  1. Bioavailability of vitamin D2 from UV-B-irradiated button mushrooms in healthy adults deficient in serum 25-hydroxyvitamin D: a randomized controlled trial, European Journal of Clinical Nutrition 2011 The 26 adults with serum 25-hydroxyvitamin D at or below 50 nanomoles per liter, the five week design, and the rise of 3.9 nanomoles per liter per week in the mushroom group against 4.7 in the supplement group
  2. Effect of Ultraviolet Light-Exposed Mushrooms on Vitamin D Status: reanalysis of biobanked sera plus a systematic review and meta-analysis, The Journal of Nutrition 2023 The pooled analysis of six randomized trials finding total 25-hydroxyvitamin D not significantly increased, a weighted mean difference of 8.6 nanomoles per liter, a probability value of 0.12, very high heterogeneity, and the fall in the vitamin D3 fraction in half the trials
  3. Mushrooms: a food-based solution to vitamin D deficiency to include in dietary guidelines, Frontiers in Nutrition 2024 The measured sunlight figures of 17.5 micrograms per 100 grams after 15 minutes and 32.5 micrograms after 60 minutes, and the trial outside the 2023 review in which mushroom D2 matched D2 and D3 supplements. This review was funded by a horticulture industry body and most of its authors were employed by a food consultancy.
  4. Effect of Ultraviolet Irradiation on Vitamin D in Commonly Consumed Mushrooms in Thailand, Foods 2023 That eight species were tested under ultraviolet B lamps rather than sunlight, that enoki responded most strongly, and that the results are reported on a dried weight basis. Dried-weight values cannot be read as fresh-weight values

Frequently Asked Questions

Do mushrooms contain vitamin D?
They can, but the ones on sale usually do not. Mushrooms carry ergosterol, which ultraviolet light converts to vitamin D2, and commercial mushrooms are grown in dark climate-controlled rooms, so the conversion never happens. Mushrooms sold as UV-treated are a different product and say so on the pack.
Does putting mushrooms in the sun actually work?
Yes, and it has been measured. In published work, 100 grams of sliced button mushrooms in midday midsummer sun reached 17.5 micrograms of vitamin D2 after 15 minutes and 32.5 micrograms after 60 minutes. That is a best case rather than a typical afternoon, because ultraviolet strength varies with season, latitude and time of day.
How long do mushrooms need in the sun?
Fifteen minutes of strong midday sun already produced a large gain in the measured work, and an hour produced roughly double. Slice them, lay them gill side up in a single layer, and use direct outdoor sun, because ordinary window glass blocks most of the ultraviolet B that does the work.
Will eating UV mushrooms raise my vitamin D level?
The evidence is genuinely mixed. A 2011 trial in adults with low vitamin D found mushrooms and a supplement raised blood levels at similar rates. A 2023 meta-analysis of six trials found total 25-hydroxyvitamin D was not significantly increased, with a weighted mean difference of 8.6 nanomoles per liter and a probability value of 0.12, and with very high disagreement between the trials.
Is vitamin D2 from mushrooms as good as vitamin D3?
Several reviews find D3 more effective at raising total vitamin D status. In half the trials covered by the 2023 review, the D3 fraction in blood fell while the D2 fraction rose, which is why a mushroom can add vitamin D to a meal without the total moving as much as expected. A separate trial found mushroom D2 matching both D2 and D3 supplements, so the question is not closed.
Which mushrooms have the most vitamin D?
Exposure matters far more than species. White button, cremini and portabella are the same species at different ages and carry most of the human research. Oyster and enoki respond strongly under lamps, and traditionally sun-dried shiitake picks up vitamin D2 as a side effect of drying.
Can I rely on mushrooms for my vitamin D?
They suit topping up a reasonable diet rather than correcting a diagnosed shortfall. A supplement gives a known dose and a tray on a balcony does not, so anyone working from a blood test should be guided by their clinician rather than by a food chart.