Climatic history and ecology are considered the most important factors moulding the spatial pattern of genetic diversity. With the advent of molecular markers, species' historical fates have been widely explored. However, it has remained speculative what role ecological factors have played in shaping spatial genetic structures within species. With an unprecedented, dense large-scale sampling and genome-screening, we tested how ecological factors have influenced the spatial genetic structures in Alpine plants. Here, we show that species growing on similar substrate types, largely determined by the nature of bedrock, displayed highly congruent spatial genetic structures. As the heterogeneous and disjunctive distribution of bedrock types in the Alps, decisive for refugial survival during the ice ages, is temporally stable, concerted post-glacial migration routes emerged. Our multispecies study demonstrates the relevance of particular ecological factors in shaping genetic patterns, which should be considered when modelling species projective distributions under climate change scenarios.