Speciation genes restrict gene flow between the incipient species and related taxa. Three decades ago, we mapped a mammalian speciation gene, hybrid sterility 1 (Hst1), in the intersubspecific hybrids of house mouse. Here, we identify this gene as Prdm9, encoding a histone H3 lysine 4 trimethyltransferase. We rescued infertility in male hybrids with bacterial artificial chromosomes carrying Prdm9 from a strain with the "fertility" Hst1(f) allele. Sterile hybrids display down-regulated microrchidia 2B (Morc2b) and fail to compartmentalize gammaH2AX into the pachynema sex (XY) body. These defects, seen also in Prdm9-null mutants, are rescued by the Prdm9 transgene. Identification of a vertebrate hybrid sterility gene reveals a role for epigenetics in speciation and opens a window to a hybrid sterility gene network.