The expansion of urban areas contributes to the growth of impervious surfaces, leading to increased pollution and altering the configuration, composition, and context of land covers. This study employed machine learning methods (partial least square regressor and the Shapley Additive exPlanations) to explore the intricate relationships between urban expansion, land cover changes, and water quality in a watershed with a park and lake. To address this, we first evaluated the spatio-temporal variation of some physicochemical and microbiological water quality variables, generated yearly land cover maps of the basin adopting several machine learning classifiers, and computed the most suitable landscape metrics that better represent the land cover. The main results highlighted the importance of spatial arrangement and the size of the contributing watershed on water quality. Compact urban forms appeared to mitigate the impact on pollutants. This research provides valuable insights into the intricate relationship between landscape characteristics and water quality dynamics, informing targeted watershed management strategies aimed at mitigating pollution and ensuring the health and resilience of aquatic ecosystems.