The required clearance distance around a hot water heater depends on whether the unit is gas or electric. Gas water heaters require a minimum service clearance of 24 inches in front and 2 inches on the rear and sides, whereas electric water heaters have no minimum clearance requirements.
Electric heaters, unlike traditional heating devices, do not require a minimum clearance. However, many electrical equipment rules prescribe a 30-inch working space on the front and sides of the heater for examination, modification, or maintenance of the electrical equipment. Additionally, the National Electrical Code suggests a three-foot clearance in front of electrical equipment and a six-foot minimum headroom requirement.