Hi Blacky,
Thanks for the great blueprint !
I am using it to automatically turn off my garage light after 5minutes when I park the car but sometimes I work in the garage and I would like to keep the light on forever. I was wondering what would be the best way to use a bypass entity similar to sensor light?
-David
You could try the motion sensor option and create a toggle helper and use that instead of a motion sensor. It just needs to have a ON / OFF state. It would work best with a motion sensor as then when you leave and you forget to turn a toggle helper OFF manually and the light stays ON forever a motion sensor will always do this for you.
So if you had a motion sensor then you would need to turn the light ON manually and the motion sensor would keep it ON with a timer to then turn it OFF once no motion is clear.
Blacky
Enhancement perhaps?
I would like to extend the timer.
For instance when I come home, my outdoor lights come on. By default they would be switched off by this blueprint in 15 minutes.
However sometimes I expect company and I would like to leave them on for, say 2 hours.
Currently, I cannot extend the existing timer due to HA timer limitations:
Error: Not possible to change timer timer.outdoorlights beyond duration
Could this blueprint have MAX as well as DEFAULT for the timer? Basically, it could start the timer with MAX value and then set it to DEFAULT. That way I could modify the running timer to exceed the initial time.
Have a look at this blueprint.
If you use the same timer with a button helper, you can add buttons to your dashboard that set the timer to predefined durationās. For example, you could create four buttons for different time intervals: 30 minutes, 2 hours, 3 hours, and 4 hours. Simply press the desired button, and the timer will be set to the corresponding duration.
Blacky
Yeah. Great suggestion. Not what iām looking for though.
I sometimes would like to āpushā the timer. Not to really predefine them. Say have a +1h button that will add as many hours to a running timer as it is pushed. I could stop the timer and start it with a new time, but as the lights are tied to the timer, they would blink.
Try the blueprint it should just update the timer. Nice suggestion⦠just push to add time in time blocks set by the user. I will put it on my list.
Blacky
Curious how this handles when a light is being set by an automation?
I have a few automations that control these same lights I do in the BP screenshot below. Thus, when the automations set the light (2 dimmers controlling the same) I dont want the 5 minute timer to turn off the dimmers/light.
Would this conflict with my other automations? Does Manual Light need a Bypass option to make it not conflict?
I cant Smart Light for 2 reasonsā¦
- it doesnt have the dimmer sync feature. (then Iād need another automation to do that)
- it only allows for 1 entity trigger
This blueprint is designed for manually turning a light ON and having it automatically turn OFF after a preset time. Itās ideal for spaces like a garbage room or areas where you frequently enter and exit within a set time frame but donāt have a motion sensor. Simply turn the light ON, and it will turn OFF automatically.
Additionally, this blueprint offers an option to use a motion sensor to keep the light ON if it was manually turned ON⦠perfect for scenarios like a reading lamp where you want the light to stay on while motion is detected or if youād like to manually turn it ON and have it remain ON as long as motion is present.
If you manually turn ON a light and donāt want the timer to turn it OFF, simply donāt use this blueprint⦠just turn the light ON as usual.
I designed this because when using the Sensor Light Blueprint, I wanted the option to manually turn ON some lights occasionally and have a motion sensor turn them all OFF together. These lights are not linked to any automation, allowing for more flexible manual control.
Edit: You can toggle the automation (Enable / Disable). There is no need for extra bypass control as the trigger is manual.
Blacky
To clarify my prior inquiry⦠the BP works well for me, just sometimes I turn on those same lights inside of other automations (for example, the automation āDinnerā) that does multiple things (set multiple lights like a scene would)
Edit: You can toggle the automation (Enable / Disable). There is no need for extra bypass control as the trigger is manual.
I think you are saying when I run the āDinnerā automation, inside that automation I should disable the Manual Light automation for a given time, then enable Manual Light again later?
I could do that yes⦠a bypass would be nice though, less work by far and less confusing later to figure out the automation constructs (All I need to do it look inside 1 automation to know when it will run or not run⦠thus, no other outside influences to keep track of. In my last system I used the enable/disable method, and its a nighmare to figure out a year or two later when you changing/enhancing/etc.
The problem you will have is when the entity used in Lights & Switches is used in another automation it canāt determine if it was turn ON manually or by another automation so this automation will run.
What are you trying to do that uses this automation with another automation?
Blacky
All my house lights are Auto-Off Timers. I have over 50 light switches/dimmers and none of them are -only- triggered by motion sensors. About 40 of them are triggered by all of these methods at any given timeā¦
- person clicking physical button
- dashboard button
- automation (scene)
In my last system I wrote all automations manually (example below) and created a helper for each switch/dimmer which needed a bypass (not all entities needed one).
When
LightXYZ = Not Off
or
MotionXYZ = On
Then
If MotionXYZ = On Then Light=Off in 10 minutes, exit ā resets light off ātimerā and exits code
If BypassXYZ = Off Then ā runs needed actions
I set Bypassās to On or Off in the other Automations as needed.
So with your BPs I must have multiple BPs per dimmer/switch when that switch needs both motion and physical control.
would it be possible to extend the automation in a way that it turns on the light if motion is detected - running the same timer as for manually switched on lights?
then it would be perfect
great blueprint - thx for sharing
thx - yes have seen it. but with sensor lights you have no option to automatically switch of the light if no motion for a while - right?
Just saw that there is a wait time option in sensor lights - great.
Maybe additional question. Does the sensor lights also trigger if I turn on the lights manually?
Not sure were the wait time isā¦
This blueprint is designed to work with or without your sensor light blueprint.
If your sensor light blueprint turns on the lights and you have a reading lamp that you turn ON from time to time manually then this blueprint will handle that for you and turn the lamp off when you leave. That is the idea behind it.
Blacky
Is it possible that the blueprint behaves incorrectly when syncing is deactivated?
With t1_start, the timer is paused and restarted when the motion detector becomes inactive again.
However, if t1_end follows during this time, the blueprint aborts in the general conditions. Reason: The timer is not active.
This ultimately means that the motion detector and the lamp are switched off, but the timer continues to run.
Why is that a problem?
I have a notification on timer.finished. And it triggers even though everything is correct.
Traces are available.
traceautomation.dev_manual_light_kinderzimmer2025-03-20T20_38_35.58369000_00.json
traceautomation.dev_manual_light_kinderzimmer2025-03-20T20_38_30.48808500_00.json
traceautomation.dev_manual_light_kinderzimmer2025-03-20T20_38_35.58461900_00.json
Say goodbye to lights left on! Step into automated lighting with an auto shut-off and a motion sensor reset.
Bug Fixes
- When timer was paused and all triggers were turned OFF manually the timer would not cancel and would resume when motion was clear. It will now go to idle when this happens.
Maintenance
- From time to time, Home Assistant updates their YAML standards and coding practices. To align with their roadmap, weāve updated the code accordingly. We will continue to apply these updates across all our blueprints as they are revised.
If you like this blueprint? Consider hitting the button in the top post
If you like my blueprints, and would like to show your support or just say thank you? Click Here
Enjoy
Blacky
Hi @Blacky,
First off, thanks for this high quality blueprint! I was working on my own version of the same concept when I stumbled upon yours, and since yours is miles ahead of mine, Iāve decided to not reinvent the wheel.
Would it be possible to add a āgrace periodā feature where the lights turn back on automatically if motion is detected during a defined period?
Many local governments in North America have adopted energy conservation rules that require lighting in certain areas of a property to be manual-on/automatic-off, such as provided for by your blueprint, but there is usually a provision for a grace period of anywhere from 15 seconds to two minutes, in order to reduce the nuisance factor and improve safety.
This functionality would be a big help to anyone who has to comply with energy codes such as ASHRAE 90.1, the IECC, or their local variants (for example, the NYCECC).