Vitamin D supplements will not prevent you from catching influenza, but may offer some level of protection depending on your unsupplemented vitamin D levels. Vitamin D is used for the production of antimicrobial peptides by the immune system, and there is evidence that supplementation may protect against respiratory infections including influenza, especially in those with lower vitamin D levels.