A water heater should be replaced if it shows the following symptoms:
Even though steel is the strongest material in the world, rust is it's #1 enemy and eats steel away. A rusty inlet valve or rust coming from your water source is a sure sign that you need to have your water heater inspected and possibly repaired or replaced. Once rust has taken over the inside of the tank, your only option is to replace the entire water heater tank, there is no salvaging from that point so always do your due diligence in staying in the know with the current state of your water heater to avoid replacement being the only option.