The short answer is yes, but if you are a homeowner that possesses the skill and knowledge to do it yourself you are allowed to file a permit with your local municipality. A permit is very important and they are becoming more important by the day. As everything in life continues to go up in price, so does the cost of making a mistake during the installation of a water heater. The water heater is the most dangerous appliance in the home. Heating water in a pressurized vessel is inherently dangerous. Water heaters usually heat with either natural / propane gas or electricity and sometimes both. Gas water heaters have exhaust which can contain carbon monoxide in the event of a malfunction. Electricity can be dangerous in an almost countless number of ways. Not to mention how much damage water can cause when it is not where it is supposed to be. All of this comes down to the responsibility of being a homeowner. As the homeowner it is your responsibility to make sure your water is installed correctly.
I have seen countless water heaters that have not been installed correctly. Sometimes there is little to no consequence and other times major property loss has happened. I have never been personally involved in a situation where a failality has happened, but there are times when it has happened unfortunately. As a homeowner not using a licensed plumber will make any of these consequences your responsibility. It could be as simple as a leak in a water line that you have to pay someone else to repair, a manufacturer not honoring their warranty because of an installation mistake. or an insurance company rejecting a claim because a non-licenced person did the installation causing the damage.
Contractor licensing is equally about responsibility and knowledge. No government is getting rich by licensing professionals. It is a community service. The people that work in these offices and inspectors in the field are certainly underpaid in almost all cases but what they do is essential. Keeping contractors responsible includes making sure their insurance is adequate, making sure the contractor properly insures their workers with workers compensation insurance and making sure their knowledge is up to date through the licence process. Did you know you could be responsible if a worker gets injured in your home and the company isn't insured? Accidents happen everyday. It's happened to our workers a few times over the years even. Licensing & the permit process is also intended to give you peace of mind knowing your next door neighbors are required to have water heaters installed by competent people. This keeps a mistake at your neighbors home from burning down your house in the event of a catastrophic event. Most catastrophic events take many mistakes coming together at once in most cases. This is why homes that have gone through years of not being kept up properly start having so many issues all at once. It's certainly a case of pay now or pay later. Hopefully it is just a home inspector flagging multiple issues when the home is being sold but one way or another problems from having people work in your home that lack the knowledge to do so will come to the surface. Those mistakes will be the responsibility of the homeowner on almost every occasion.
Now using a licensed contractor that properly permits your next water heater covers you for as long as 25 years in the State of Ohio. Long past the life on any water heater nowadays. Once your water heater is inspected, no manufacturer will be able to decline warranty coverage down the road due to improper installation. The inspection sticker will be right on the tank in case you ever need it. No home inspector will see that inspection sticker and say there was a problem with the installation. In the world of inspectors, the local government inspector is the ruler of them all. Also no home insurance company will ever be able to decline coverage due to improper installation.
In the event something does go wrong and you used a licensed company, what happens? You can start off by calling the company knowing they had insurance at the time of your installation or project. Since they are insured they can simply refer your issue to the insurance company they had at the time of your installation. You are more likely to get this resolved since it is the insurance company paying the bill and not the contractor. If that doesn't work, you have the ability to reach out to your municipality that licensed the contractor. They will have their insurance information on file for the contractor that was used. Nothing gets a contractor moving quicker than a call from the city. Some municipalities require contractors to file cash bonds to receive a licence and that bond can be called in at any time in the event there is a problem with contractor's insurance or if the city believes it is an urgent matter that needs funds immediately. Insurance companies are responsible for the work their contractor provided for up to 25 years in the State of Ohio if it is deemed a "craftsmanship issue."
These are all things to consider when deciding to replace your water heater with a new one.