That depends on two things: the type of water heater and the quality of the water heater. If you’re using a conventional water heater that incorporates a tank, otherwise known as a boiler, then you can expect to replace it more frequently than if you use a tankless or instantaneous water heater. Then there is the issue of quality. A high quality conventional water heater will last about a decade if maintained well. A high quality tankless water heater will last at least 2 decades if maintained well. You may need to have repairs done on each every once in a while, but you shouldn’t have to replace the whole thing until several years have gone by