Two enzymes, dUTP pyrophosphatase and uracil-DNA glycosylase, prevent the misincorporation of uracil into the genome in distinct manners. The atomic structures of these proteins complexed with substrate analogs reveal the structural basis for uracil recognition and suggest a novel mechanism of DNA repair.