WAGS Water & Gas shut off valve will shut off both water and gas to a water heater or other gas fired device like a boiler if a water leak is detected. You put a water pan under the water heater or boiler and if water is detected by the probe the water and gas will automatically be shut off.