Levels of gene flow among populations vary both inter- and intraspecifically, and understanding the ecological bases of variation in levels of gene flow represents an important link between the ecological and evolutionary dynamics of populations. The effects of habitat spatial structure on gene flow have received considerable attention; however, most studies have been conducted at a single spatial scale and without background data on how individual movement is affected by landscape features. We examined the influence of habitat connectivity on inferred levels of gene flow in a high-altitude, meadow-dwelling butterfly, Parnassius smintheus. For this species, we had background data on the effects of landscape structure on both individual movement and on small-scale population genetic differentiation. We compared genetic differentiation and patterns of isolation by distance, based on variation at seven microsatellite loci, among three regions representing two levels of connectivity of high-altitude, nonforested habitats. We found that reduced connectivity of habitats, resulting from more forest cover at high altitudes, was associated with greater genetic differentiation among populations (higher estimated FST), a breakdown of isolation by distance, and overall lower levels of inferred gene flow. These observed differences were consistent with expectations based on our knowledge of the movement behaviour of this species and on previous population genetic analyses conducted at the smaller spatial scale. Our results indicate that the role of gene flow may vary among groups of populations depending on the interplay between individual movement and the structure of the surrounding landscape.