1. Seed dispersal is a key process in the generation and maintenance of genetic diversity and genetic differentiation of plant populations in tropical ecosystems. During the Last Quaternary, most seed-dispersing megafauna was lost globally, but whether this has caused dispersal limitation, loss of genetic diversity, and increased genetic differentiation between plant populations with large, megafaunal fruits (i.e., > 4 cm - megafruits) remains unclear. 2. Here, we assessed whether megafrugivore extinctions in Madagascar (e.g., giant lemurs, elephant birds) have affected the genetic diversity and genetic differentiation of four animal-dispersed Malagasy palm (Arecaceae) species with large (Borassus madagascariensis), medium-sized (Hyphaene coriacea, Bismarckia nobilis), and small (Chrysalidocarpus madagascariensis) fruits. We integrated double-digest restriction-site-associated DNA sequencing (ddRAD) of 167 individuals from 25 populations with (past) distribution ranges for extinct and extant seed-dispersing animal species, climate and human impact data, and applied linear mixed-effects models to explore the drivers of variation in genetic diversity and genetic differentiation across Malagasy palm populations. 3. We detected higher genetic diversity in species with megafruits than in the species with small fruits, and genetic differentiation was lowest for the human-used medium-sized megafruit species. Furthermore, we found that a higher number of shared extinct megafrugivore species between palm population pairs was associated with less genetic differentiation, indicating higher gene flow, whereas no relationship with extant frugivores (that are not able to swallow and disperse the seeds) was found. Finally, genetic diversity decreased with road density, whereas genetic differentiation decreased with increasing human population density, but only for populations with megafruits. 4. Our results suggest that the legacy of megafrugivores regularly achieving long dispersal distances is still reflected in the genetic diversity and genetic differentiation of palms that were formerly dispersed by such large animals. Furthermore, high genetic diversity and low genetic differentiation were possibly maintained after the megafauna extinctions through human-mediated dispersal, long generation times, and long lifespans of these palms. Our study illustrates how integrating genetics with ecological data on species interactions, climate, and human impact, provides novel insights into the consequences of megafauna extinctions for plants with megafruits.