“The latitudinal diversity gradient (LDG) is a prevalent feature of modern ecosystems across diverse clades1–4. Recognized for well over a century, the causal mechanisms for LDGs remain disputed, in part because numerous putative drivers simultaneously covary with latitude1,3,5. The past provides the opportunity to disentangle LDG mechanisms because the relationships among biodiversity, latitude and possible causal factors have varied over time6–9. Here we quantify the emergence of the LDG in planktonic foraminifera at high spatiotemporal resolution over the past 40 million years, finding that a modern-style gradient arose only 15 million years ago. Spatial and temporal models suggest that LDGs for planktonic foraminifera may be controlled by the physical structure of the water column. Steepening of the latitudinal temperature gradient over 15 million years ago, associated with an increased vertical temperature gradient at low latitudes, may have enhanced niche partitioning and provided more opportunities for speciation at low latitudes. Supporting this hypothesis, we find that higher rates of low-latitude speciation steepened the diversity gradient, consistent with spatiotemporal patterns of depth partitioning by planktonic foraminifera. Extirpation of species from high latitudes also strengthened the LDG, but this effect tended to be weaker than speciation. Our results provide a step change in understanding the evolution of marine LDGs over long timescales.” in Nature