Microglia are the resident immune cells of the brain. Increasingly, they are recognized as important mediators of normal neurophysiology, particularly during early development. Here we demonstrate that microglia are critical for ocular dominance plasticity. During the visual critical period, closure of one eye elicits changes in the structure and function of connections underlying binocular responses of neurons in the visual cortex. We find that microglia respond to monocular deprivation during the critical period, altering their morphology, motility and phagocytic behaviour as well as interactions with synapses. To explore the underlying mechanism, we focused on the P2Y12 purinergic receptor, which is selectively expressed in non-activated microglia and mediates process motility during early injury responses. We find that disrupting this receptor alters the microglial response to monocular deprivation and abrogates ocular dominance plasticity. These results suggest that microglia actively contribute to experience-dependent plasticity in the adolescent brain.