Some bacteria can transfer to new host species, and this poses a risk to human health. Indeed, an estimated 60% of all human pathogens have originated from other animal species. Similarly, human-to-animal transitions are recognized as a major threat to sustainable livestock production, and emerging pathogens impose an increasing burden on crop yield and global food security. Recent advances in high-throughput sequencing technologies have enabled comparative genomic analyses of bacterial populations from multiple hosts. Such studies are providing new insights into the evolutionary processes that underpin the establishment of bacteria in new host niches. A better understanding of the genetic and mechanistic basis for bacterial host adaptation may reveal novel targets for controlling infection or inform the design of approaches to limit the emergence of new pathogens.