The A-repeat region of the lncRNA Xist is critical for X inactivation and harbors several N6-methyladenosine (m6A) modifications. How the m6A modification affects the conformation of the conserved AUCG tetraloop hairpin of the A-repeats and how it can be recognized by the YTHDC1 reader protein is unknown. Here, we report the NMR solution structure of the (m6A)UCG hairpin, which reveals that the m6A base extends 5′ stacking of the A-form helical stem, resembling the unmethylated AUCG tetraloop. A crystal structure of YTHDC1 bound to the (m6A)UCG tetraloop shows that the (m6A)UC nucleotides are recognized by the YTH domain of YTHDC1 in a single-stranded conformation. The m6A base inserts into the aromatic cage and the U and C bases interact with a flanking charged surface region, resembling the recognition of single-stranded m6A RNA ligands. Notably, NMR and fluorescence quenching experiments show that the binding requires local unfolding of the upper stem region of the (m6A)UCG hairpin. Our data show that m6A can be readily accommodated in hairpin loop regions, but recognition by YTH readers requires local unfolding of flanking stem regions. This suggests how m6A modifications may regulate lncRNA function by modulating RNA structure.