The efficient management of urban water distribution networks is crucial for public health and urban development. One of the major challenges is the quick and accurate detection of leaks, which can lead to water loss, infrastructure damage, and environmental hazards. Many existing leak detection methods are ineffective, especially in complex and aging pipeline networks. If these limitations are not overcome, it can result in a chain of infrastructure failures, exacerbating damage, increasing repair costs, and causing water shortages and public health risks. The leak issue is further complicated by increasing urban water demand, climate change, and population growth. Therefore, there is an urgent need for intelligent systems that can overcome the limitations of traditional methodologies and leverage sophisticated data analysis and machine learning technologies. In this study, we propose a reliable and advanced method for detecting leaks in water pipes using a framework based on Long Short-Term Memory (LSTM) networks combined with autoencoders. The framework is designed to manage the temporal dimension of time-series data and is enhanced with ensemble learning techniques, making it sensitive to subtle signals indicating leaks while robustly dealing with noise signals. Through the integration of signal processing and pattern recognition, the machine learning-based model addresses the leak detection problem, providing an intelligent system that enhances environmental protection and resource management. The proposed approach greatly enhances the accuracy and precision of leak detection, making essential contributions in the field and offering promising prospects for the future of sustainable water management strategies.