The presence of disinfection by-products (DBPs) increases the mutagenicity of water and may pose adverse health effects. Gut microbiota exerts a fundamental role on host physiology, and how extrinsic perturbations influence its composition has been increasingly examined. However, the effect of DBPs on gut microbiota is still poorly understood. In the present study, adult zebrafish were exposed to different concentrations of dichloroacetamide (DCAcAm, an emerging nitrogenous DBP) for 30 days. Sequencing of 16S rRNA amplicons revealed a significant change in the richness and diversity of microbiota in the gut of DCAcAm-exposed zebrafish. At the phylum level, the abundance of Proteobacteria decreased and the abundance of Fusobacteria and Firmicutes increased significantly in the gut after exposure to 100 and 500 μg/L DCAcAm. At the genus level, the abundances of several bacteria which are considered pathogens or opportunistic pathogens in fish and closely related to fish metabolism, disease and inflammation (Aeromonas, Stenotrophomonas, Bacteroides and Ralstonia) increased in the DCAcAm-treated groups. Our results reveal that DBPs in drinking water potentially affect gut microbiota composition, which may contribute to the toxicity assessment of DBPs in future and provide new insight into the complex interactions between the DBPs in drinking water and host health.