Repetitive transcranial magnetic stimulation (rTMS) is a non-invasive brain stimulation technique that is widely used in clinical practice for therapeutic purposes. Nevertheless, the mechanisms that mediate its therapeutic effects remain poorly understood. Recent work implicates that microglia, the resident immune cells of the central nervous system, have a defined role in the regulation of physiological brain function, e.g. the expression of synaptic plasticity. Despite this observation, no evidence exists for a role of microglia in excitatory synaptic plasticity induced by rTMS. Here, we used repetitive magnetic stimulation of organotypic entorhino-hippocampal tissue cultures to test for the role of microglia in synaptic plasticity induced by 10 Hz repetitive magnetic stimulation (rMS). For this purpose, we performed PLX3397 (Pexidartinib) treatment to deplete microglia from tissue culture preparations. Using whole-cell patch-clamp recordings, live-cell microscopy, immunohistochemistry and transcriptome analysis, we assessed structural and functional properties of both CA1 pyramidal neurons and microglia to correlate the microglia phenotype to synaptic plasticity. PLX3397 treatment over 18 days reliably depletes microglia in tissue cultures, without affecting structural and functional properties of CA1 pyramidal neurons. Microglia-depleted cultures display defects in the ability of CA1 pyramidal neurons to express plasticity of excitatory synapses upon rMS. Notably, rMS induces a moderate release of proinflammatory and plasticity-promoting factors, while microglial morphology stays unaltered. We conclude that microglia play a crucial role in rMS-induced excitatory synaptic plasticity.