To exist in a wide range of environmental niches, bacteria must sense and respond to a variety of external signals. A primary means by which this occurs is through two-component signal transduction pathways, typically composed of a sensor histidine kinase that receives the input stimuli and then phosphorylates a response regulator that effects an appropriate change in cellular physiology. Histidine kinases and response regulators have an intrinsic modularity that separates signal input, phosphotransfer, and output response; this modularity has allowed bacteria to dramatically expand and diversify their signaling capabilities. Recent work has begun to reveal the molecular basis by which two-component proteins evolve. How and why do orthologous signaling proteins diverge? How do cells gain new pathways and recognize new signals? What changes are needed to insulate a new pathway from existing pathways? What constraints are there on gene duplication and lateral gene transfer? Here, we review progress made in answering these questions, highlighting how the integration of genome sequence data with experimental studies is providing major new insights.