Preliminary, primary, secondary, and tertiary treatments are the main steps used to treat wastewater. Preliminary treatment removes solids like grit, grease and rags. Primary treatment uses sedimentation to remove suspended solids. Secondary treatment uses biological processes like activated sludge to remove organic matter through microbial digestion. Tertiary treatment further removes nutrients and disinfects the water before environmental discharge or reuse.