Green hydrogen production by water electrolysis is an inevitable solution for global sustainability. However, for making hydrogen energy as next-generation fuel, enough pure water and associated cost is required, which is another critical issue that must be resolved. An attempt has been made to produce hydrogen gas from low-grade and wastewater using alkaline water splitting. The electrodes, electrolyte, voltage, and impurity level have significantly affected hydrogen generation. Turbidity and total dissolved solids have been found to be important factors whose removal can enhance hydrogen production from wastewater. A high-strength sulfonated polyvinylidene fluoride (HSPVDF) ultrafiltration (UF) membrane was used to produce high-quality advanced treated water. Tertiary UF membrane treatment has contributed substantially to residual impurity removal and improved hydrogen generation. The study suggests that wastewater and advanced treated watercan effectively utilize green hydrogen generation with impurity removal. Based on this finding, the potential applicability for achieving energy independence in municipal wastewater treatment plants was examined. Replacing water with wastewater can be a new dimension of the hydrogen economy.