Li et al. show that maternal exposure to a Western-type diet accelerates atherosclerosis in adult offspring by inducing inflammatory memory in fetal endothelial cells through AP-1-mediated chromatin dynamics. This process, enhanced by 27-hydroxycholesterol, increases chromatin accessibility to inflammatory genes, which can be mitigated by inhibiting AP-1 binding.