Emerging evidence has shown that vitamin D deficiency may be related with community-acquired pneumonia (CAP), but individually published studies showed inconclusive results. The aim of this study was to quantitatively summarize the association between vitamin D and the CAP.We conducted this meta-analysis though a systematic literature search of PubMed, Medline, and EMBASE up to 31 September 2018 with the following keywords 'vitamin D' or 'cholecalciferol' or '25-hydroxyvitamin D' or '25(OH)D' in combination with 'community-acquired pneumonia' or 'CAP' or 'pneumonia' with no limitations. This meta-analysis was performed following the guidelines of Meta-analysis of Observational Studies in Epidemiology. The association between vitamin D levels and CAP were measured as odds ratio (OR) and weighted mean difference (WMD). Results were combined using a random-effect or a fix-effect meta-analysis, and sensitivity analyses were conducted to explore potential factors.Eight observational studies involving 20,966 subjects were included. In this meta-analysis, CAP patients with vitamin D deficiency (serum 25(OH)D levels <20 ng/mL) experienced a significantly increased risk of CAP (odds ratio (OR) = 1.64, 95% confidence intervals (CI): 1.00, 2.67), and an obvious decrease of -5.63 ng/mL (95% CI: -9.11, -2.14) in serum vitamin D was demonstrated in CAP patients. Sensitivity analysis showed that exclusion of any single study did not materially alter the overall combined effect.The evidence from this meta-analysis indicates an association between vitamin D deficiency and an increased risk of CAP patients. However, well-designed trails are required to determine the explicit effect of vitamin D supplementation.