OBJECTIVE: Stroke is a main cause of disability and mortality worldwide. It has been reported that ischemic preconditioning (IP) has neuroprotective effects against stroke. This study aimed to verify the mechanism by which calcium-sensing receptor (Casr) inhibition-mediated M2 microglial transformation in the IP protects against stroke, which will provide a potential therapeutic target for stroke. METHODS: Middle cerebral artery occlusion (MCAO) rats and oxygen-glucose deprivation (OGD) neurons were used in this study. IP was induced via the transient MCAO and OGD methods. RNA sequencing (RNA-Seq) was used to explore the underlying key molecules. Western blotting and immunohistochemistry were performed to detect the expression of Casr and the M1 and M2 microglial markers. CCK8 was used to detect cell viability. The calcium concentration was detected via the use of Fluo-4 AM, a fluorescence probe. The Casr inhibitor NPS2143 and the Casr activator R568 were used to explore the role of Casr in M2 microglial transformation and neuroprotection. RESULTS: We first revealed that IP induced M2 microglial transformation in ischemic injury. In addition, MCAO injury increased Casr expression and the calcium concentration, which was inhibited by IP. Furthermore, Casr activation inhibited the M2 microglial transformation induced by IP. Finally, we found that Casr inhibition improved the survival rate, alleviated neurological deficits, and reduced the infarct volume induced by MCAO. CONCLUSIONS: We confirmed that Casr-related neuroprotection induced by IP is associated with the transformation of M2 microglia. These findings can be used to understand the protective mechanisms of IP against ischemic stroke.