[1] Its specificity in higher fungi is thought to be related to the climatic instabilities (highly varying humidity and moisture conditions) encountered by these organisms in their typical ecological niches (plant and animal surfaces, soil).
[2] This advantage could be linked to the presence of two conjugated double bonds in the structure (B-ring) of ergosterol giving it antioxidant properties.
The "azole" class of antifungal agents inhibit the enzyme that performs these demethylation steps in the biosynthetic pathway between lanosterol and ergosterol.
[8][9] Fungi are grown industrially to enable ergosterol extraction and preparation as a powder for sale as a vitamin D2 dietary supplement and food additive.
Ingestion of large amounts can cause hypercalcemia, which (if prolonged) can lead to calcium salt deposits in the soft tissues and kidneys.