Advances in sequencing have enabled the identification of mutations acquired by bacterial pathogens during infection 1- 10 . However, it remains unclear whether adaptive mutations fix in the population or lead to pathogen diversification within the patient 11, 12 . Here, we study the genotypic diversity of Burkholderia dolosa within people with cystic fibrosis by re-sequencing individual colonies and whole populations from single sputum samples. Extensive intra-sample diversity reveals that mutations rarely fix within a patient's pathogen population—instead, diversifying lineages coexist for many years. When strong selection is acting on a gene, multiple adaptive mutations arise but neither sweeps to fixation, generating lasting allele diversity that provides a recorded signature of past selection. Genes involved in outer-membrane components, iron scavenging and antibiotic resistance all showed this signature of within-patient selection. These results offer a general and rapid approach for identifying selective pressures acting on a pathogen in individual patients based on single clinical samples.