Objective To investigate the effects of TLR3 and TLR9 signaling pathway on brain injury during CPB in rats pretreated with sevoflurane and its possible molecular mechanism. Methods SD rats were randomly assigned to sham group, CPB group, and Sev group. Brain tissue was obtained at before CPB (T0), at CPB for 30 minutes (T1), 1 hour after CPB (T3), and 3 hours after CPB (T5). ELISA was used to measure S100-β and IL-6. Western blot was utilized to determine TLR3 and TLR9 expression. TUNEL was applied to detect neuronal apoptosis. Results Compared with CPB group, at T1, at termination after 1 hour of CPB (T2), T3, 2 hours after CPB (T4) and T5, S100-β and IL-6 decreased in Sev group. Compared with CPB group, IFN-β were increased in Sev group, except T0. Compared with CPB group, TLR3 expression increased, and TLR9 and NF-κB decreased in Sev group. The apoptotic neurons were less in Sev group than in CPB group (P < 0.05). Conclusion Sevoflurane intervention can activate TLR3 and TLR9 signaling pathway, upregulate TLR3 expression and downstream TRIF expression, decrease TLR9 expression, and downregulate downstream NF-κB expression in CPB rat models, thereby mitigating brain injury induced by inflammatory response during CPB.