One minute of action
Water from a failed heater in Sleepy Valley spreads into slab, framing and drywall while somebody decides what to do. The useful steps are short.
Close the cold inlet on top of the tank, or the property main if it will not turn. Shut the fuel — the gas valve on the supply pipe, or the breaker. Move anything stored around the unit off the floor. Never cap the relief valve to stop a drip.
What can wait
No hot water with no leak and no gas smell is usually a part, and a part at midnight is not worth an emergency rate. A pilot that will not hold, a breaker that trips straight back or a dead display can wait for daylight.
What cannot
Running water that will not stop, any smell of gas — leave and call the utility from outside — a commercial kitchen or laundry without hot water during service, or a panel that smells hot after repeated trips.
Afterwards
The repair follows from what failed: a shell means replacement, a valve or fitting means a repair. Closing the inlet is what turns an emergency into a decision.