The first five minutes
Most of the damage from a failed heater happens while someone stands looking at it. Water under a unit soaks into the slab, the framing and the drywall behind it, and a pan without a drain just holds it against the tank.
Close the cold inlet on top of the tank. If it will not turn, the property's main shut-off is the next option.
Shut the fuel off. The gas valve on the supply pipe at the heater, or the breaker on an electric unit. A heater that keeps firing with its water gone destroys its own elements.
Move what is stored around it — boxes, paint, anything on the floor within reach of the water.
Do not cap the relief valve to stop a drip. It is doing its job.
What can wait for morning
No hot water with no leak and no gas smell is usually a part failure, and a part failure at ten at night is not worth an emergency rate. If the pilot will not stay lit, the breaker trips again immediately, or the display is dead, a few hours costs nothing but a cold shower.
What must not wait
Running water that will not stop, any smell of gas, a commercial kitchen or laundry with no hot water during service, or an electric heater that has tripped repeatedly with a burning smell at the panel.
What the hour does and does not promise
The phone is answered around the clock. What that guarantees is a conversation and advice on making the property safe; the visit is arranged on that call with a time you have agreed to.