Dexamethasone (DEX) is a hormone drug that is often detected in wastewater treatment plants, but its impact on activated sludge systems is unknown. This study explored the long-term effects of DEX on nutrient removal, microbial activities, microbial assembly, and microbial interactions in the activated sludge system. During the 90-day DEX exposure experiment, both chemical oxygen demand and total nitrogen removal efficiencies were initially inhibited and then recovered. Microbial activities, i.e., specific oxygen uptake rate and denitrification, did not differ significantly from that of the control reactor (p > 0.05), possibly due to the secretion of extracellular polymers that act as a protective barrier against excess reactive oxygen species induced by DEX. This barrier protects cell membrane integrity and ensures stable treatment performance. Analysis of microbial assembly identified the drift of stochastic processes (from 92.7 % to 51.8 %) and homogeneous selection of deterministic processes (from 1.6 % to 38.7 %) as the main driving forces of microbial community structure succession under long-term DEX stress. Although long-term exposure to 1000 μg/L DEX did not significantly increase the abundance levels of functional bacteria (Nitrosomonas and 996-1) and key genes (AmoCAB and Hao), the ammonia oxidation capacity of the activated sludge system was enhanced. Analysis of microbial interactions indicated that streamlining of functional subnetworks and increased cooperation were the primary reasons. This is the first study to explore the long-term effects of DEX on activated sludge and provide insights into microbial interaction and assembly. Moreover, the findings of this study broaden our knowledge and lay an experimental foundation for reducing risks associated with hormone drugs.