While traits and trait plasticity are partly genetically based, investigating epigenetic mechanisms may provide more nuanced understanding of the mechanisms underlying response to environment. Using AFLP and methylation-sensitive AFLP, we tested the hypothesis that differentiation to habitats along natural salt marsh environmental gradients occurs at epigenetic, but not genetic loci in two salt marsh perennials. We detected significant genetic and epigenetic structure among populations and among subpopulations, but we found multilocus patterns of differentiation to habitat type only in epigenetic variation for both species. In addition, more epigenetic than genetic loci were correlated with habitat in both species. When we analysed genetic and epigenetic variation simultaneously with partial Mantel, we found no correlation between genetic variation and habitat and a significant correlation between epigenetic variation and habitat in Spartina alterniflora. In Borrichia frutescens, we found significant correlations between epigenetic and/or genetic variation and habitat in four of five populations when populations were analysed individually, but there was no significant correlation between genetic or epigenetic variation and habitat when analysed jointly across the five populations. These analyses suggest that epigenetic mechanisms are involved in the response to salt marsh habitats, but also that the relationships among genetic and epigenetic variation and habitat vary by species. Site-specific conditions may also cloud our ability to detect response in replicate populations with similar environmental gradients. Future studies analysing sequence data and the correlation between genetic variation and DNA methylation will be powerful to identify the contributions of genetic and epigenetic response to environmental gradients.