Abstract N6-methyladenosine (m6A), a major modification of mRNAs, plays critical roles in RNA metabolism and function. In addition to the internal m6A, N6, 2′-O-dimethyladenosine (m6Am) is present at the transcription start nucleotide of capped mRNAs in vertebrates. However, its biogenesis and functional role remain elusive. Using a reverse genetics approach, we identified PCIF1, a factor that interacts with the Ser5-phosphorylated C-terminal domain of RNA polymerase II, as cap-specific adenosine methyltransferase (CAPAM) responsible for N6-methylation of m6Am. Crystal structure of CAPAM in complex with substrates revealed the molecular basis of cap-specific m6A formation. A transcriptome-wide analysis revealed that N6-methylation of m6Am promotes the translation of capped mRNAs. Thus, a cap-specific m6A writer promotes translation of mRNAs starting from m6Am.