Integration of the Internet of Things (IoT) into the fields of wastewater treatment and water quality prediction has the potential to revolutionize traditional approaches and address urgent challenges, considering the global demand for clean water and sustainable systems. This comprehensive article explores the transformative applications of smart IoT technologies, including artificial intelligence (AI) and machine learning (ML) models, in these areas. A successful example is the implementation of an IoT-based automated water quality monitoring system that utilizes cloud computing and ML methods to effectively address the above-mentioned issues. The IoT has been employed to optimize, simulate, and automate various aspects, such as monitoring and managing natural systems, water-treatment processes, wastewater-treatment applications, and water-related agricultural practices like hydroponics and aquaponics. This review presents a collection of significant water-based applications, which have been combined with the IoT, artificial neural networks, or ML and have undergone critical peer-reviewed assessment. These applications encompass chlorination, adsorption, membrane filtration, monitoring water quality indices, modeling water quality parameters, monitoring river levels, and automating/monitoring effluent wastewater treatment in aquaculture systems. Additionally, this review provides an overview of the IoT and discusses potential future applications, along with examples of how their algorithms have been utilized to evaluate the quality of treated water in diverse aquatic environments.