Whenever HA reboots both bath fans start
Could you please provide us your YAML of the automation? This YAML code are the settings you have selected in the automation so I can help. To do this go into your automation, top right 3 dots, Edit in YAML, copy all the code, come back to the forum and in your reply at the top tool bar click on ā</>ā and paste code in there.
Blacky ![]()
Automation seems to be working great turning the fan on but it doesnt seem to be turning the fan off. I simply just want to use the falling % and a simple delay. What am i missing?
alias: Bathroom Humidity Exhaust Fan
description: ""
use_blueprint:
path: Blackshome/bathroom-humidity-exhaust-fan.yaml
input:
trigger: sensor.bathroom_humidity_derivative
fan_speed_low: []
fan_switch:
entity_id: switch.bathroom_fan
time_out: 60
include_max_humidity: maximum_humidity_enabled
max_humidity: 70
bathroom_humidity_sensor: sensor.bathroom_temperature_sensor_humidity
time_delay: 30
falling_humidity: -1.5
Your Maximum Humidity is very low. This option is mainly designed for situations like when one person finishes a shower and another starts soon after causing humidity to rise again. I have mine on 85% for summer and 87% for winter.
For your time delay of 30 and safeguard of 60. I have 7.5 for summer with a safeguard of 17 and 15 for winter with a safeguard of 20.
First try and disable the Maximum Humidity Option. Test it and see if it all works well.
Then when that works have one shower, let it finish, then start another shortly after⦠see what the humidity does. Use the high end of your humidity levels of your 2nd shower to set the Maximum Humidity Option. Itās not meant to trigger the automation ON when the humidity goes from below 70 to above 70 without having a shower. Is designed for what happens when we have the 2nd shower, humidity drops a bit then rises again and the Derivative Sensor wont trigger it back ON because the move is to low.
Blacky ![]()
Iād like to ask a dumb question as someone new to the home assistant world. Iāve searched endlessly through the comments and donāt see anyone talking about the fan itself.
I currently have a Leviton Decora In-Wall Humidity Sensor & Fan Control
I was thinking Iād just replace it with a basic smart switch that is Home Assistant capable.
I went through your FAQ - Can you show us your full set up? and started questioning what Iām even doing here lolā¦
So will my idea work just fine? Are people doing it this way or a completely different way? Am I overlooking something?
Welcome to the community.
There are many types of smart switches you can choose.
- I use Shelly PM3 wired to the fans and a separate switch on the wall to control the fan.
- You could also use a smart plug that is plugged into a power outlet that the fan plugs into.
The main thing to think about is having a switch on the wall that is not linked to your fan. Then you get all the benefits from the blueprint. Something like a Shelly 2PM. One relay for the fan and the other relay for the switch.
The next step is the humidity sensor. Depending what and how you would like to do it you normally have 2 options.
- My choice is to use ESPHome and build my own humidity sensor. It is plugged in and not battery powered. This is connected via WiFi and communicate every 60 seconds.
- Battery powered. You can get WiFi ones but I have found them to be unreliable due to WiFi trying to save power and donāt communicate to HA enough. There are other sensors that use Bluetooth, Z-Wave (HA seems to be putting a lot of effort in Z-Wave lately), Zigbee etc. What you looking for is for it to communicate frequently.
Then you need to consider location of your sensor. Best location is on the exhaust grill then followed by high up on the wall or ceiling where the humidity will be like close to your shower head.
Once you have all that covered your ready to go.
Blacky ![]()
Thanks so much for the response @Blacky!
- Just curious why youād use this option versus the smart plug option in 2). my first thought is that itās more work to modify the wiring versus just using a smart plug.
- Somehow I didnāt realize that a fan would just have a regular wall plug⦠it shows that Iāve never opened up an exhaust fan before! This just sounds like the easier/noob friendly option yeah?
Can you explain this a bit more? I just donāt get why I would want a wall switch that is NOT linked to my fan. What would the point of it be then?
If I went with the smart switch option above along with a moisture sensor tucked into the exhaust grill then wouldnāt I be good to go? The wall switch would essentially just be a manual way to turn the fan on then no?
Yes it is but I have a Shelly PM4 (not PM3) and that controls both bathroom fans, toilet fan and LED transformer. It is more work⦠it is just what works for you is the best way.
Itās the easier option because you donāt need to change any wiring, but you wonāt get the full benefit from the blueprint. In most homes, the wall switch controls power to the wall outlet, and the fan is plugged into that outlet. If you use a smart plug, the wall switch must stay ON 24/7, and you lose the ability to manually control the fan from the wall. That might be fine for you, but itās a limitation.
A better option is to use a Shelly 2PM (or any device with two relays).
Hereās how it works:
- Have your electrician wire the fan to one relay. Home Assistant can now turn the fan ON/OFF.
- Wire the wall switch to the second relay only.
This makes the wall switch visible in Home Assistant without controlling any load directly.
In the blueprint, you can treat this wall switch as the Manual Trigger or Manual Fan Switch. The blueprint will handle turning the fan ON/OFF and resetting the switch state automatically so there are no conflicts. We need a fan and a switch (two independent entities) in HA if the fan is wired to the switch (one entity) then you just have a fan and it wont work like that.
I use a push-button wall switch myself because it doesnāt have a fixed ON (down) or OFF (up) position, itās just a momentary button. My ESP32 controls the switch, humidity sensor, LUX sensor and motion sensor so the lights turn ON to. I control exactly how everything works in the ESP32 and it is cost effective. You just need a power point in the ceiling or double up the one have already to power the ESP32.
Since you were considering replacing the wall switch anyway, using a Shelly 2PM lets you use the existing wiring and keeps everything neatly behind the switch. This gives you a fan and a switch (two independent entities).
With this setup, the wall switch still gives you manual control to turn the fan ON, while Home Assistant automatically handles turning it OFF based on your chosen blueprint settings.
I hope this hasnāt confused you and that it helps. In the end, itās completely up to you and whatever works best for your setup.
If you already have a smart plug (or you can get one as you use it somewhere in your home later), try that option first with your sensor since itās quick and easy. Just tape the wall switch ON so it canāt be turned OFF, and control the fan through the smart plug. Once youāve confirmed everything works and youāre happy with it, you can look at upgrading the wall switch with a Shelly 2PM or a similar device. You could keep the smart plug and join the positive wires to the plug bypassing the current switch and add a smart switch with noting connected. Would work the same but then you have 2 devices not 1. There are many ways to do this.
Blacky ![]()
Thanks Blacky. A lot to take in here. Iāll think it through and experiment before begging you to hold my hands any more
. Itās very appreciated how helpful and responsive you are!
It is a lot to get your head around but once you understand this blueprint it is gold. Is one, if not my favorite blueprint and I canāt imagine living without it now.
Always here to help if you need it.
Blacky ![]()
Hi @Blacky, first of all, love this blueprint, the main reason for setting up HA was mainly for this bathroom extractor fan to come on only when needed. So thanks!
I have recently bought the Sonoff SNZB-01P wireless button to use as a manual trigger for when guests of the toilet may wish to turn on the fan. ![]()
But it does not show up in the trigger list.
I do have a helper I use as a manual trigger, and wanted to add an additional entity for this.
If I try setting up my own automation, I can add the button and switch the fan ON/OFF, but there is no timer, so in theory this could run until pressed again. (I also looked at your timer blueprint, but same thing, cannot find on the list)
Ideally, wanted to use the button to switch on the fan, if not pressed again time out after 20min. If pressed during the timer then switch the fan off.
The Sonoff button has single, double, and hold setting. Iām just trying to use the single press for now.
Appreciate any help. Iām fairly new to HA. ![]()
Thank you.
I have Version: 2.6 installed of your blueprint.
Welcome to the community. Yeah this is one of my favorite blueprints too.
This helper your referring to would probably be a toggle helper. What you can do is download my
Press Button - Turn ON & OFF Entities blueprint. Use the button in the Press Button and then use your toggle helper as the Main Entity. That is if you like the button to trigger the Manual Trigger. If you would like it to trigger the Manual Fan Switch then just creat a diffrent toggle helper and use it in the Main Entity of the press button blueprint and then use that toggle helper in the Manual Fan Switch.
Blacky ![]()
This is. Great blueprint, although Iāve had a couple false positives lately that have annoyed the wife because the fan is in the bathroom attached to our bedroom. I think theyāre related to a finicky Bluetooth connection to the sensor.
Iād like to disable the entity based on time of day, so it canāt run at all past 10 PM or so. This also helps if Iām out late and sheās sleeping when I start the shower. Wife sleeping > exhaust fan!
Related, somewhat. We have a window in our bathroom, so Iād like to disable the light during the day. Itās only needed at night.
Any suggestions?
Sometimes this relates to some fine tuning by looking at your Derivative Sensor. You may need to increase it a bit. Go back to the history and see what happened then fine tune it. When you look at the history add all three entities. Fan, Derivative Sensor and humidity sensor so you can get a real understanding what is happening. You could be using Maximum Humidity and that is why it triggered to. I have no false triggers but I did have to fine tune it a bit so just a heads up.
Create a time helper or a schedule helper and add it into the bypass. This will keep the automation functioning correctly. You will probably use bypass option 2.
If you need more control over your lights, use my
Sensor Light blueprint for your lighting automation.
If you are using the automation link to keep the light ON (for example, because the motion sensor canāt detect you while youāre in the shower), simply add that automation link toggle helper into Bypass Option 3 in the Sensor Light blueprint.
This way:
- If the lights are OFF because it is daytime, they will stay OFF.
- If the lights are ON because it is nighttime, they will stay ON as expected.
How and when your lights turn ON is fully handled inside the Sensor Light blueprint. It includes many flexible options, and this is the exact setup I personally use⦠so I know it works reliably, as it was originally developed for this purpose. In the FAQ I show you a full set up I have.
Blacky ![]()
Firstly thank you a really helpful automation. I use it for my bathroom fan but I also use it to heat the towel rail when I get in the shower.
I have seperate manual switches set up, is there a way to see how far through the auto off time delay you are, Id love to be able to add that as a dial module in the bubble card that controls the manual toggle?
NO, the delays are internal in HA. I donāt believe you can show them on a dashboard.
Is this for your heated towel rail? For this have a look at my
Trigger - Run ON Timer. Make sure you use the timer helper option. This way your separate manual switches can turn on the towel rail. You can have 4 different times (4 different buttons = different time or you can have it so when the fan comes ON it heats the towel rail) with a Increment Duration. You then can display the timer in your dashboard.
Blacky ![]()
Hi @Blacky thanks a lot for your great automation.
Question, is there a way you can help me implement a fan start delay? Imagine the bathroom is nice and warm, I would like the automation to start 5-10 min after it initially detects the rise in humidity, as the exhaust will pull in outside cold air, and the extra 10 min of high humidity is usually fine.
I couldnāt really find this in the FAQ or searching in the topic, let me know if yes.
thank you ![]()
There is nothing in this blueprint that will do that. What you may be able to do it to turn ON a toggle helper in the blueprint instead of your fan. Then have a small custom automation that says if toggle helper is ON for X (5-10 min) then turn fan ON⦠and ⦠if toggle helper is OFF then turn fan OFF. Now when this blueprint turns ON your toggle helper you will have what your looking for.
Blacky ![]()
Thanks Iāll try that
Thanks for the help, will have a look.

