Commensal enteric bacteria have evolved systems that enable growth in the ecologic niche of the host gastrointestinal tract. Animals evolved parallel mechanisms to survive the constant exposure to bacteria and their metabolic by-products. We propose that drug transporters encompass a crucial system to managing the gut microbiome. Drug transporters are present in the apical surface of gut epithelia. They detoxify cells from small molecules and toxins (xenobiotics) in the lumen. Here, we review what is known about commensal structure in the absence of the transporter ABCB1/P-glycoprotein in mammalian models. Knockout or low-activity alleles of ABCB1 lead to dysbiosis, Crohn's disease and ulcerative colitis in mammals. However, the exact function of ABCB1 in these contexts remain unclear. We highlight emerging models-the zebrafish Danio rerio and sea urchin Lytechinus pictus-that are poised to help dissect the fundamental mechanisms of ATP-binding cassette (ABC) transporters in the tolerance of commensal and pathogenic communities in the gut. We and others hypothesize that ABCB1 plays a direct role in exporting inflammatory bacterial products from host epithelia. Interdisciplinary work in this research area will lend novel insight to the transporter-mediated pathways that impact microbiome community structure and accelerate the pathogenesis of inflammatory bowel disease when perturbed. This article is part of the theme issue 'Sculpting the microbiome: how host factors determine and respond to microbial colonization'.