Cancer genomes contain large numbers of somatic mutations, but few of these mutations drive tumor development. Current approaches identify driver genes based on mutational recurrence, or they approximate the functional consequences of nonsynonymous mutations using bioinformatic scores. While passenger mutations are enriched in characteristic nucleotide contexts, driver mutations occur in functional positions, which are not necessarily surrounded by a particular nucleotide context. We observed that mutations in contexts that deviate from the characteristic contexts around passenger mutations provide a signal in favor of driver genes. We therefore developed a method that combines this feature with the signals traditionally used for driver gene identification. We applied our method to whole-exome sequencing data from 11,873 tumor-normal pairs and identified 460 driver genes that clustered into 21 cancer-related pathways. Our study provides a resource of driver genes across 28 tumor types with additional driver genes identified based on mutations in unusual nucleotide contexts.