To stop a water heater from leaking, first turn off the power and shut off the cold water supply. Identify and fix the leak source by tightening connections or replacing faulty parts. If sediment build-up is the cause, flush the tank to remove it. For persistent issues, consult a professional for further assistance.