DNA methylation refers to the addition of cytosine residues in a CpG context (5′‐cytosine‐phosphate‐guanine‐3′). As one of the most common mechanisms of epigenetic modification, it plays a crucial role in regulating gene expression and in a diverse range of biological processes across all multicellular organisms. The relationship between temperature and DNA methylation and how it acts on the adaptability of migratory insects remain unknown. In the present work, a 5,496 bp full‐length complementary DNA encoding 1,436 amino acids (named MsDnmt1) was cloned from the devastating migratory pest oriental armyworm, Mythimna separata Walker. The protein shares 36.8–84.4% identity with other insect Dnmt1 isoforms. Spatial and temporal expression analysis revealed that MsDnmt1 was highly expressed in adult stages and head tissue. The changing temperature decreased the expression of MsDnmt1 in both high and low temperature condition. Besides, we found that M. separata exhibited the shortest duration time from the last instar to pupae under 36°C environment when injected with DNA methylation inhibitor. Therefore, our data highlight a potential role for DNA methylation in thermal resistance, which help us to understand the biological role adaptability and colonization of migratory pest in various environments.