DNA and histone modifications have notable effects on gene expression1. Being the most prevalent internal modification in mRNA, the N6-methyladenosine (m6A) mRNA modification is as an important post-transcriptional mechanism of gene regulation2-4 and has crucial roles in various normal and pathological processes5-12. However, it is unclear how m6A is specifically and dynamically deposited in the transcriptome. Here we report that histone H3 trimethylation at Lys36 (H3K36me3), a marker for transcription elongation, guides m6A deposition globally. We show that m6A modifications are enriched in the vicinity of H3K36me3 peaks, and are reduced globally when cellular H3K36me3 is depleted. Mechanistically, H3K36me3 is recognized and bound directly by METTL14, a crucial component of the m6A methyltransferase complex (MTC), which in turn facilitates the binding of the m6A MTC to adjacent RNA polymerase II, thereby delivering the m6A MTC to actively transcribed nascent RNAs to deposit m6A co-transcriptionally. In mouse embryonic stem cells, phenocopying METTL14 knockdown, H3K36me3 depletion also markedly reduces m6A abundance transcriptome-wide and in pluripotency transcripts, resulting in increased cell stemness. Collectively, our studies reveal the important roles of H3K36me3 and METTL14 in determining specific and dynamic deposition of m6A in mRNA, and uncover another layer of gene expression regulation that involves crosstalk between histone modification and RNA methylation.