Stunault et al. show that the ketogenic diet drives extensive transcriptional reprogramming of the hippocampus through histone post-translational modifications, leading to altered short-term plasticity and reduced synaptic integration at the circuit level.