We examined the evolutionary history of leading multidrug resistant hospital pathogens, the enterococci, to their origin hundreds of millions of years ago. Our goal was to understand why, among the vast diversity of gut flora, enterococci are so well adapted to the modern hospital environment. Molecular clock estimation, together with analysis of their environmental distribution, phenotypic diversity, and concordance with host fossil records, place the origins of the enterococci around the time of animal terrestrialization, 425-500 mya. Speciation appears to parallel the diversification of hosts, including the rapid emergence of new enterococcal species following the End Permian Extinction. Major drivers of speciation include changing carbohydrate availability in the host gut. Life on land would have selected for the precise traits that now allow pathogenic enterococci to survive desiccation, starvation, and disinfection in the modern hospital, foreordaining their emergence as leading hospital pathogens.