The evolution of transgenerational epigenetic adaptation is driven by the invasion and stable inheritance of epialleles. Here, we describe a population-genetic model subject to environmentally-induced epigenetic effects in order to investigate the conditions under which an epigenetically modifiable allele (epiallele) can invade a population insensitive to such cues. Here, epigenetically modifiable individuals have the potential to develop a phenotype that is suitable for their predicted future environment and, provided this prediction is correct, possess a biological advantage compared to their non-modifiable counterpart. However, when individuals experience an environment that 'mismatches' their phenotype, an advantage over unmodifiable individuals may be precluded and instead they experience a decrease in fitness. These epigenetic modifications are then inherited by the next generation which are either epigenetically reset to match their environment or, by resisting environmental cues, maintain their epigenetic status. We found that when environmental cues were common, a severe fitness cost of mismatch between environment and phenotype meant that the disadvantage was too costly and epialleles were less likely to invade. Moreover, for a wide range of parameters, a higher rate of germline epigenetic resetting decreased the likelihood of epiallele invasion. Accordingly, we found that both the frequency of environmental influences and the rate of resetting were central parameters in this system.