BACKGROUND: Increasing evidence supports the immunomodulatory effect of vitamin D on allergic diseases. The combined role of prenatal and postnatal vitamin D status in the development of food sensitization (FS) and food allergy remains understudied. METHODS: Plasma 25-hydroxyvitamin D (25(OH)D) levels of 460 children in the Boston Birth Cohort (BBC) were measured at birth and early childhood, and the subjects were genotyped for rs2243250 (C-590T) in the IL4 gene. We defined FS as specific IgE levels of >/=0.35 kUA/l to any of eight common food allergens; we defined persistently low vitamin D status as cord blood 25(OH)D <11 ng/ml and postnatal 25(OH)D <30 ng/ml. RESULTS: We observed a moderate correlation between cord blood 25(OH)D at birth and venous blood 25(OH)D measured at 2-3 y (r = 0.63), but a weak correlation at <1 y (r = 0.28). There was no association between low vitamin D status and FS at any single time point alone. However, in combination, persistence of low vitamin D status at birth and in early childhood increased the risk of FS (odds ratio (OR) = 2.03, 95% confidence interval (CI): 1.02-4.04), particularly among children carrying the C allele of rs2243250 (OR = 3.23, 95% CI: 1.37-7.60). CONCLUSION: Prenatal and early postnatal vitamin D levels, along with individual genetic susceptibility, should be considered in assessing the role of vitamin D in the development of FS and food allergy.