BackgroundThe causal relationship between gut microbiota and cerebrovascular disease remains unknown, despite several recent studies reporting an association between the two.MethodsTo assess this relationship, we conducted a two-sample Mendelian randomization (MR) using summary statistics data from published genome-wide association studies (GWAS). This analysis allowed us to identify bacterial taxa that may affect cerebrovascular disease. Furthermore, we performed reverse MR to further analyze the significant bacterial taxa. Finally, we conducted a two-step MR analysis to examine the mediating role of metabolic factors [systolic blood pressure (SBP), type 2 diabetes (T2D), and body mass index (BMI)] in the association between gut microbiota and cerebrovascular disease. Additionally, a series of sensitivity analyses were carried out to validate the robustness of our findings.ResultsOur results showed that a genetically predicted high abundance of family Porphyromonadaceae reduced the risk of intracranial aneurysms (IA). Moreover, using inverse variance weighted (IVW) estimates, we found a nominal causal relationship between seventeen gut microbiota and IA, as well as its subtypes. In the case of stroke and its subtypes, we observed a nominal causal relationship with thirteen, eleven, eleven, nine, and eight bacteria for AS, AIS, CES, LAS, and SVS, respectively. Reverse MR analysis showed no significant causal relationship between intracranial aneurysms and gut microbiota. However, we did find that genetically predicted any stroke (AS) and any ischemic stroke (AIS) reduced the abundance of family Clostridiaceae1 (OR: 0.74, 95% CI: 0.62–0.87, p = 3.39 × 10−4, and OR: 0.75, 95% CI: 0.66–0.87, p = 7.06 × 10−5, respectively). Furthermore, genetic prediction of AIS (OR: 0.87, 95% CI: 0.77–0.99, p = 3.05 × 10−2) was associated with a reduced abundance of the order Clostridiales. Moreover, genus Streptococcus exhibited effects on AS, AIS, and SVS which were mediated by T2D. Conversely, the association between genus Eubacterium brachy group and AIS was mediated by SBP. No significant heterogeneity of instrumental variables or horizontal pleiotropy was observed.ConclusionThis MR analysis indicates that there exists a beneficial or detrimental causal effect of gut microbiota composition on cerebrovascular disease. And SBP and T2D may play mediating role in this process.