A potential relationship between dysregulation of immune/inflammatory pathways and cognitive impairment has been suggested in severe mental illnesses (SMI), such as schizophrenia (SZ) and bipolar (BD) spectrum disorders. However, multivariate relationships between peripheral inflammatory/immune-related markers and cognitive domains are unclear, and many studies do not account for inter-individual variance in both cognitive functioning and inflammatory/immune status. This study aimed to investigate covariance patterns between inflammatory/immune-related markers and cognitive domains and further elucidate heterogeneity in a large SMI and healthy control (HC) cohort (SZ = 343, BD = 289, HC = 770). We applied canonical correlation analysis (CCA) to identify modes of maximum covariation between a comprehensive selection of cognitive domains and inflammatory/immune markers. We found that poor verbal learning and psychomotor processing speed was associated with higher levels of interleukin-18 system cytokines and beta defensin 2, reflecting enhanced activation of innate immunity, a pattern augmented in SMI compared to HC. Applying hierarchical clustering on covariance patterns identified by the CCA revealed a high cognition—low immune dysregulation subgroup with predominantly HC (24% SZ, 45% BD, 74% HC) and a low cognition—high immune dysregulation subgroup predominantly consisting of SMI patients (76% SZ, 55% BD, 26% HC). These subgroups differed in IQ, years of education, age, CRP, BMI (all groups), level of functioning, symptoms and defined daily dose (DDD) of antipsychotics (SMI cohort). Our findings suggest a link between cognitive impairment and innate immune dysregulation in a subset of individuals with severe mental illness.