Gut bacteria in modern humans and apes are not simply acquired from the environment, a new study suggests, but instead coevolved for millions of years with hominids to help shape our immune systems. The results pave the way for studies informing the evolutionary processes underlying the unique symbiotic relationships between us and our microbes. How the bacteria that inhabit our gut came to be there remains unknown. In particular, scientists have been unclear about the role symbiosis played in shaping gut microbiome composition. Here, to provide greater insight into this question, Andrew Moeller et al. developed a method to compare rapidly-evolving bacterial gene sequences in fecal samples and applied it across chimpanzees from Tanzania, bonobos from the Democratic Republic of the Congo, gorillas from Cameroon, and humans from the United States. This allowed them to contrast the family trees of several bacterial lineages, ultimately finding that they closely matched the evolutionary patterns of their hosts. What's more, bacterial species distinct to one host were rarely transferred to other hosts, the researchers found. This suggests that bacteria evolved in unique patterns along with their hosts, and that gut bacteria residing within present-day humans are descended from ancestral bacterial symbionts.