Abstract: Western Eurasia witnessed several large-scale human migrations during the Holocene1?5. Here, to investigate the cross-continental efects of these migrations, we shotgun-sequenced 317 genomes-mainly from the Mesolithic and Neolithic periods-from across northern and western Eurasia. These were imputed alongside published data to obtain diploid genotypes from more than 1,600 ancient humans. Our analyses revealed a 'great divide' genomic boundary extending from the Black Sea to the Baltic. Mesolithic hunter-gatherers were highly genetically diferentiated east and west of this zone, and the efect of the neolithization was equally disparate. Large-scale ancestry shifts occurred in the west as farming was introduced, including near-total replacement of hunter-gatherers in many areas, whereas no substantial ancestry shifts happened east of the zone during the same period. Similarly, relatedness decreased in the west from the Neolithic transition onwards, whereas, east of the Urals, relatedness remained high until around 4,000 BP, consistent with the persistence of localized groups of hunter-gatherers. The boundary dissolved when Yamnaya-related ancestry spread across western Eurasia around 5,000 BP, resulting in a second major turnover that reached most parts of Europe within a 1,000-year span. The genetic origin and fate of the Yamnaya have remained elusive, but we show that hunter-gatherers from the Middle Don region contributed ancestry to them. Yamnaya groups later admixed with individuals associated with the Globular Amphora culture before expanding into Europe. Similar turnovers occurred in western Siberia, where we report new genomic data from a 'Neolithic steppe' cline spanning the Siberian forest steppe to Lake Baikal. These prehistoric migrations had profound and lasting efects on the genetic diversity of Eurasian populations.