Turning off a Nest controlled heat/air conditioning system after a open door/window sensor

Does anyone know of a way to have a nest thermostat turn off the heat/air conditioning after a open door/window sensor has been detected for a set period of time?


Yes, I have a simple smartapp for that use case called “WindowOrDoorOpen” at my github. The smartapp can work for a Nest or any other ST connected thermostat which follows the ST standard capabilities (and handle the “off” or “eco” commands).

  • You can select multiple door/window contacts (up to 30 can be managed in a single instance, 6 open contacts can be tracked at the same time). You get tjhe relevant contact message (open/close) for each tracked contact (not a generic message).
  • You can define the number of minutes between notifications (ex. notifications every 2 minutes)
  • (optional) You can define a threshold for turning off the Nest Tstat (ex. after 5 minutes)
  • (optional) You can integrate a voice notification using speakers
  • You can define a max number of notifications (ex. 2 notifications max).
  • You can set a flag to set the thermostats to eco/away mode instead of turning them off.

Refer to:

Or the github integration:

Owner yracine
Repo Name SmartThingsPublic
Branch master


Thank you!

Will it return to the original sate once the contacts are closed.

Yes, it will.

This is automation builtin to nest manager.


1 Like

Which is also free (donations welcome but not required).

@yvesracine, I’m really excited about this smartapp (WindwOrDoorOpen) but I am having difficulties with it… where’s the proper place to request some help? Thx

I found your post searching for door sensors to turn off nest thermostat. Your program seems like what I’m looking for. I’m totally green to all of this home automation and could use a lot of help. I’m sorry if I posted in the wrong area. Any and all help would be greatly appreciated. Right now I have a wink hub 2 and two best thermostats. I would like to have door sensors that when a door is left open for 3- mins an alarm will go off, then if the door isn’t closed for another 2- mins, it will turn the a/c off. And when the door is closed it will turn the a/c back on to the same temperature or a predetermined temperature. Thanks again and I hope I’m in the right spot.


Nest documentation http://thingsthataresmart.wiki/index.php?title=NST_Manager

As we discussed over email, If you want a resilient implementation with the best design which will not give you any upgrade or auth tokens issues, then My Next Tstat implementation is for you:

There is a smartapp at my github called WindowOrDoorOpen that will fulfill your use case and more:

  • The smartapp can set your thermostat(s) to away or turn it off (latter not recommended for locations where a ST outage could cause mold b/c of high humidity).

  • You can specify the number and frequency of notifications (for your open contacts) and if you want you can also add verbal notifications with your ST connected speakers.


Would this work with a garage door tilt sensor such as the Ecolink TILTZWAVE2.5-ECO? https://discoverecolink.com/product/z-wave-plus-garage-door-tilt-sensor-diy/


Yes, it would work as long as the DTH will report the open/close status as a standard contact under ST.

Please note: you’d need My Next ManagerV2, available at my store to expose your Nest devices.