Abstract Urban wastewater systems discharge organic matter, nutrients and other pollutants (including toxic substances) to receiving waters, even after removing more than 90% of incoming pollutants from human activities. Understanding their interactions with the receiving water bodies is essential for the implementation of ecosystem-based management strategies. Using mathematical modeling and sensitivity analysis we quantified how 19 operational variables of an urban wastewater system affect river water quality. The mathematical model of the Congost system (in the Besòs catchment, Spain) characterizes the dynamic interactions between sewers, storage tanks, wastewater treatment plants and the river. The sensitivity analysis shows that the use of storage tanks for peak shaving and the use of a connection between two neighboring wastewater treatment plants are the most important factors influencing river water quality. We study how the sensitivity of the water quality variables towards changes in the operational variables varies along the river due to discharge locations and river self-purification processes. We demonstrate how to use the approach to identify interactions and how to discard non-influential operational variables.