Mice harbouring a mutation in the gene encoding gastric intrinsic factor (Gif), a protein essential for the absorption of vitamin B12/cobalamin (Cbl), have potential as a model to explore the role of vitamins in infection. The levels of Cbl in the blood of Gif tm1a/tm1a mutant mice were influenced by the maternal genotype, with offspring born to heterozygous (high Cbl, F1) mothers exhibiting a significantly higher serum Cbl level in comparison to those born to homozygous (low Cbl, F2) equivalents. Low Cbl levels correlated with susceptibility to infectious challenge with Salmonella enterica serovar Typhimurium or Citrobacter rodentium, and this susceptibility phenotype was moderated by Cbl administration. Transcriptional and metabolic profiling revealed Cbl deficient mice exhibited a profile with characteristics of the Warburg effect that was further exacerbated by infection. Our findings demonstrate a role for Cbl in bacterial infection, with potential general relevance to dietary deficiency and infection susceptibility.