Treated wastewaters are an important alternative water supply for communities in dry climates all over the world. This study investigates using waste stabilization ponds (WSPs) to treat wastewater and the design of a solar photovoltaic pumping system to transfer the water to an Oasis in the Moroccan desert. The Oasis is currently about 5 ha in size and is irrigated with 24 m3/day of underground water. The wastewater is subjected to physicochemical and bacteriological analyses, also monitoring of operation, maintenance and loading rates of the WSPs for 12 months. To build a solar water pumping system, data on the system's components as well as local climatic data are obtained. The design optimization is done by simulation software PVsyst. WSPs provide reduced rates of BOD and fecal coliforms of 95 and 99%, respectively, with an average effluent concentration of 20 mg/l and 195 CFU. The exploitation of solar energy for pumping 24 m3/day requires five panels with a unit nominal power of 440 W for each panel and 2200 W for the entire system. This allows us to save about 1,500 kg of CO2 emissions per year, protect the region's fragile water resources and ensure the sustainability of the Oasis.