Systemic infection induces conserved physiological responses that include both resistance and 'tolerance of infection' mechanisms. Temporary anorexia associated with an infection is often beneficial, reallocating energy from food foraging towards resistance to infection or depriving pathogens of nutrients. However, it imposes a stress on intestinal commensals, as they also experience reduced substrate availability; this affects host fitness owing to the loss of caloric intake and colonization resistance (protection from additional infections). We hypothesized that the host might utilize internal resources to support the gut microbiota during the acute phase of the disease. Here we show that systemic exposure to Toll-like receptor (TLR) ligands causes rapid α(1,2)-fucosylation of small intestine epithelial cells (IECs) in mice, which requires the sensing of TLR agonists, as well as the production of interleukin (IL)-23 by dendritic cells, activation of innate lymphoid cells and expression of fucosyltransferase 2 (Fut2) by IL-22-stimulated IECs. Fucosylated proteins are shed into the lumen and fucose is liberated and metabolized by the gut microbiota, as shown by reporter bacteria and community-wide analysis of microbial gene expression. Fucose affects the expression of microbial metabolic pathways and reduces the expression of bacterial virulence genes. It also improves host tolerance of the mild pathogen Citrobacter rodentium. Thus, rapid IEC fucosylation appears to be a protective mechanism that utilizes the host's resources to maintain host-microbial interactions during pathogen-induced stress.