A gas water heater can last 25 years. That doesn’t mean you should keep it that long.
Heating water is one of the largest energy expenses in your home. Because newer water heaters are so much more energy efficient than older ones, it could be worth it to replace yours at the first sign of trouble rather than throwing money into repairs.
If you have an electric water heater and it goes on the fritz, go ahead and replace it with an energy-efficient gas unit (if available) which will use about half of the energy.
If your gas model acts up, consider how old it is and whether your gas bill has been creeping up as the unit ages. Once a water heater is about 10 years old, its operating efficiency can diminish by 50 percent or more, so replacing it rather than repairing it probably will cost less in the long run.
When you do, consider an “on-demand” or “tank-less” water heater, which heats water only when you need it and doesn’t have a big tank full of water to keep warm when nobody’s home. Tank-less models use about 30 percent less energy than traditional gas water heaters.