Mucosal microbiota differ significantly from fecal microbiota and may play a different role in the pathophysiology of irritable bowel syndrome (IBS). The aims of this study were to determine if the composition of mucosal microbiota differed between IBS, or IBS bowel habit (BH) subtypes, and healthy controls (HCs). Sigmoid colon mucosal biopsies were obtained from 97 Rome-positive patients with IBS (28% IBS-constipation, 38% IBS-diarrhea, 24% IBS-mixed, and 10% IBS-unsubtyped) and 54 HCs, from which DNA was extracted. 16S rRNA gene sequencing and microbial composition analysis were performed. Group differences in α and β diversity and taxonomic level differences were determined using linear regression while controlling for confounding variables. IBS BH subtype was associated with microbial α diversity (P = 0.0003) with significant differences seen in the mucosal microbiota of IBS-constipation versus IBS-diarrhea (P = 0.046). There were no significant differences in α or β diversity in the mucosal microbiota of IBS versus HCs (P = 0.29 and 0.93, respectively), but metagenomic profiling suggested functional differences. The relative abundance of Prevotella_9 copri within IBS was significantly correlated with increased abdominal pain (r = 0.36, P = 0.0003), which has not been previously reported in IBS. Significant differences in the mucosal microbiota were present within IBS BH subtypes but not between IBS and HCs, supporting the possibility of IBS BH subtype-specific pathogenesis. Increased Prevotella copri may contribute to symptoms in patients with IBS.NEW & NOTEWORTHY Gut mucosal microbiota differs significantly from fecal microbiota in irritable bowel syndrome (IBS) and may play a different role in its pathophysiology. Investigation of colonic mucosal microbiota in the largest cohort of patients with IBS and healthy controls accounting for confounding variables, including diet demonstrated significant differences in mucosal microbiota between IBS bowel habit subtypes but not between IBS and healthy controls. In addition, the study reported gut microbiota is associated with abdominal pain in patients with IBS.