The human gut microbiota can restrict the growth of pathogens to prevent them from colonizing the intestine (‘colonization resistance’). However, antibiotic treatment can kill members of the gut microbiota (‘gut commensals’) and reduce competition for nutrients, making these nutrients available to support the growth of pathogens. This disturbance can lead to the growth and expansion of pathogens within the intestine (including antibiotic-resistant pathogens), where these pathogens can exploit the absence of competitors and the nutrient-enriched gut environment. In this review, we discuss nutrient competition between the gut microbiota and pathogens. We also provide an overview of how nutrient competition can be harnessed to support the design of next-generation microbiome therapeutics to restrict the growth of pathogens and prevent the development of invasive infections.