Vitamin D helps the body absorb calcium and is essential for strong bones, alongside its roles in muscle and immune function. The body makes it in the skin from sunlight, and a few foods (oily fish, eggs, fortified foods) supply some.
Too little vitamin D weakens bones. Supplements help people who are deficient or get little sun, but taking very high doses does not build extra bone and can be harmful. See calcium and vitamin D for bones, and ask a clinician about the right amount for you.