Buying a new home can feel like a high-stakes gamble—especially if you’re concerned about that rusty old water heater hulking in the corner. New units can cost $1,000 (or more), so understanding exactly how much life your unit has left is imperative. But how long does a water heater really last?

Here’s what you need to know to understand its potential life span. Assuming you’re maintaining your water heater properly, most models should last between eight and 12 years. Even if your model is running perfectly, consider replacing a unit that’s more than a decade old. A sudden leak could cause a significant flood.

“The most common failure of residential heaters that requires the unit to be replaced is a leaking tank,” says Chris Gos, the general manager of Levy & Son Service Experts in Dallas. And while all water heaters will eventually sacrifice themselves to the mechanical gods, proper maintenance can ensure your unit’s longevity.

In addition to proper insulation—which reduces heat loss—make sure you’re flushing the tank and checking the anode rod each year. Those basic tasks ensure the inside remains efficient and rust-free.

An “undersize” heater might also fail quicker, says Gos, especially if it’s gas.

“When a gas heater is regularly depleted of hot water due to heavy usage, the burner fires more frequently,” he says. This can cause the tank to deteriorate and damage the interior glass lining.

When to replace your water heater

A sudden leak is an obvious sign that your water heater needs replacing, but that’s the worst-case scenario. If your heater’s already leaking, you’re in serious trouble. Here are some other warning signs:

  • Rusty water typically indicates the unit is (spoiler alert!) rusting internally. But it could mean galvanized piping is a bit rusty, too. Draining the water from your heater can indicate where the problem lies.
  • Cold water is a nasty surprise, especially in mid-February. While this might just mean a repair is needed, make sure to call an expert immediately—the entire unit may need replacing.
  • Rumbling from built-up sediment lining the tank’s bottom might mean you need a new heater ASAP.
  • Leaks are an easy visual indicator that something is not right with your water heater. Call a qualified plumber immediately to assess the condition of your unit.