DNA methylation alterations are related to multiple molecular mechanisms. The DNA context of CpG sites plays a crucial role in the maintenance and stability of methylation patterns. The quantitative relationship between DNA composition and DNA methylation has been studied in normal as well as pathological conditions, showing that DNA methylation status is highly dependent on the local sequence context. In this work, we describe this relationship by analyzing the DNA sequence context associated to methylation profiles in both physiological and pathological conditions. In particular, we used DNA motifs to describe methylation stability patterns in normal tissues and aberrant methylation events in cancer lesions. In this manuscript, we show how different groups of DNA sequences can be related to specific epigenetic events, across normal and cancer tissues, and provide a thorough structural and functional characterization of these sequences.