Importance Obstructive sleep apnea (OSA) in children is linked with alterations in the gut microbiome. The influence of adenotonsillectomy (AT), a primary intervention for OSA, on gut microbiota dynamics relative to disease severity remains to be elucidated. Objective This study aimed to investigate the impact of OSA severity and AT on the gut microbiome in pediatric patients. Design A prospective observational study. Setting Tertiary referral center. Participants A cohort of 55 pediatric patients treated with AT for OSA. Intervention Total tonsillectomy and adenoidectomy procedures. Main Outcome Measures Comprehensive evaluations included in-laboratory polysomnography and 16S rRNA gut microbiome profiling at baseline, and again at 3rd and 12thmonth following surgery. Results Initial findings showed uniform α-diversity across different severities of OSA, while β-diversity was significantly elevated in the severe OSA subgroup. Certain gut microbiota taxa ( Lachnospiraceae NK4A136 group, Ruminococcaceae UCG-002, Ruminococcaceae UCG-014, Alloprevotella, Christensenellaceae R-7 group, Ruminococcaceae UCG-005, Lactobacillus murinus, and Prevotella nigrescens) were found to inversely correlate with the apnea-hypopnea index (AHI). Significant post-AT improvements in AHI and other polysomnographic metrics were observed. Notably, AHI changes post-AT were positively associated with microbial α-diversity (species richness), β-diversity, and specific bacterial taxa ( Enterobacter, Parasutterella, Akkermansia, Roseburia, and Bacteroides plebeius DSM 17135), but negatively with other taxa ( Fusicatenibacter, Bifidobacterium, UBA1819, Ruminococcus gnavus group, Bifidobacterium longum subsp. Longum, and Parabacteroides distasonis) and specific metabolic pathways (purine metabolism, transcription factors, and type II diabetes mellitus). The postoperative patterns of α- and β-diversity mirrored baseline values. Conclusions and Relevance This study documents significant changes in the gut microbiome of pediatric patients after AT, including variations in α- and β-diversities, bacterial communities, and inferred metabolic functions. These changes suggest a potential association between the surgical intervention and microbiome alterations, although further studies are necessary to discern the specific contributions of AT amidst possible confounding factors such as antibiotic use.