BackgroundMajor depressive disorder (MDD) and bipolar disorder (BD) are prevalent psychiatric conditions linked to inflammatory processes. However, it is unclear whether associations of immune cells with these disorders are likely to be causal. MethodsWe used two-sample Mendelian randomization (MR) approach to investigate the relationship between 731 immune cells and the risk of MDD and BD. Rigorous sensitivity analyses are conducted to assess the reliability, heterogeneity, and horizontal pleiotropy of the findings. ResultsGenetically-predicted CD27 on IgD+ CD38− unswitched memory B cell (inverse variance weighting (IVW): odds ratio (OR) [95 %]: 1.017 [1.007 to 1.027], p = 0.001), CD27 on IgD+ CD24+ B cell (IVW: OR [95 %]: 1.021 [1.011 to 1.031], p = 4.821E−05) and other 12 immune cells were associated with increased risk of MDD in MR, while HLA DR++ monocyte %leukocyte (IVW: OR [95 %]: 0.973 [0.948 to 0.998], p = 0.038), CD4 on Central Memory CD4+ T cell (IVW: OR [95 %]: 0.979 [0.963 to 0.995], p = 0.011) and other 13 immune cells were associated with decreased risk of MDD in MR. Additionally, CD33+ HLA DR+ Absolute Count (IVW: OR [95 %]: 1.022[1.007 to 1.036], p = 0.007), CD28+ CD45RA− CD8+ T cell %T cell (IVW: OR [95 %]: 1.024 [1.008 to 1.041], p = 0.004) and other 18 immune cells were associated with increased risk of BD in MR, while CD62L on CD62L+ myeloid Dendritic Cell (IVW: OR [95 %]: 0.926 [0.871 to 0.985], p = 0.014), IgD− CD27− B cell %lymphocyte (IVW: OR [95 %]: 0.918 [0.880 to 0.956], p = 4.654E−05) and other 13 immune cells were associated with decreased risk of BD in MR. ConclusionsThis MR study provides robust evidence supporting a causal relationship between immune cells and the susceptibility to MDD and BD, offering valuable insights for future clinical investigations. Experimental studies are also required to further examine causality, mechanisms, and treatment potential for these immune cells for MDD and BD.