IntroductionThe prevalence of vitamin D deficiency varied among populations and regions worldwide. In addition, the association between vitamin D deficiency and health outcomes remained controversial. Our study aimed to investigate the prevalence of vitamin D deficiency and its association with mortality risk among non-institutional middle-aged and older adults in the United States.MethodThe study population included 11,119 adult participants aged between 50 and 79 years in the 2007–2016 National Health and Nutrition Examination Survey (NHANES). Vitamin D status was divided as ≤ 30 (severely deficient), 30.1–50 (moderately deficient), 50.1–75 (insufficient), 75.1–100 (sufficient), and > 100 nmol/L (very sufficient). NHANES data were linked to National Death Index to ascertain the survival status and cause of death.ResultsThe population aged 61.5 years (survey-weighted) and 47.9% were men. Among them, 4.6% were severely vitamin D deficient, 15.2% moderately deficient, and 33.6% insufficient. Individuals with higher vitamin D levels tended to be female, older, white people, non-smoker, non-single, more educated, with higher family income, and lower body mass index. During a median follow-up of 97.0 months, a total of 1,585 participants died (15.9 per 10,000 person-months). The crude analysis showed that vitamin D deficiency, but not vitamin D insufficiency, correlated to higher all-cause mortality risk. The association remained similar after adjusting for potential confounders, showing that vitamin D deficiency (HR: 1.38, 95% CI 1.15–1.66), but not vitamin D insufficiency (HR: 1.03, 95% CI 0.88–1.20), correlated to higher all-cause mortality risk. In addition, we showed that vitamin D deficiency was an independent risk factor for death from pneumonia (HR: 3.82, 95% CI 1.14–12.86) but not from cardiovascular diseases, cancer, or cerebrovascular diseases.ConclusionIn summary, among middle-aged and older adults in the United States, nearly 20% were vitamin D deficient. Vitamin D deficiency, but not vitamin D insufficiency, correlated to increased mortality risk.