A. It's possible to install a gas water heater in a closet or other enclosed space, but it's important to ensure that the space meets ventilation requirements and local building codes. A gas water heater requires proper ventilation to prevent the buildup of dangerous gases, such as carbon monoxide.