There are few things in a home that receive less attention than the toilet.
It is always there. It does its job. Nobody really wants to think about it.
Until it doesn’t.
A small leak, a toilet that keeps running, excessive humidity after a shower, or an unnoticed water problem can turn into an expensive and unpleasant surprise surprisingly quickly.
That makes World Toilet Day, held on 19 November, a rather unexpected opportunity to talk about smart homes.
Not because Home Assistant can make your toilet more exciting.
It probably cannot.
But Home Assistant can help you monitor the things around it: water, humidity, temperature, leaks, ventilation and unusual behaviour.
And that is where things get interesting.
The bathroom is a surprisingly good smart-home environment
Bathrooms have several characteristics that make them ideal for automation.
They often contain:
- Water
- High humidity
- Heating
- Ventilation
- Lights
- Motion or occupancy
- Temperature changes
- Doors and windows
- Plumbing that you would rather not have fail
Many of these things can already be monitored by Home Assistant.
A few inexpensive sensors can therefore turn a completely ordinary bathroom into a room that can detect problems before they become obvious.
The key is not to automate everything.
The key is to notice when something is different from normal.
Start with temperature and humidity
A temperature and humidity sensor is one of the simplest additions to a bathroom.
Temperature is useful for comfort, but humidity is where things get particularly interesting.
After a shower, relative humidity can rise rapidly.
A smart ventilation system can use this information to decide when ventilation is actually needed rather than simply running according to a fixed schedule.
For example:
Humidity rises above a threshold β start ventilation.
Then:
Humidity returns to normal β stop ventilation.
This is more useful than simply running the fan for 20 minutes after every shower.
The exact threshold depends on the room, sensor location and ventilation system. A bathroom that normally sits at 45% relative humidity may need a different strategy from one that naturally sits at 60%.
The important thing is detecting a significant change.
A simple bathroom ventilation automation
Assuming Home Assistant has a humidity sensor and a controllable ventilation fan, a basic automation could look like this:
alias: Bathroom - High Humidity Ventilation
description: Start bathroom ventilation when humidity becomes high
triggers:
- trigger: numeric_state
entity_id: sensor.bathroom_humidity
above: 70
actions:
- action: fan.turn_on
target:
entity_id: fan.bathroom
This is intentionally simple.
In a real installation, you would probably add a timer or a second automation that switches the fan off when humidity has dropped again.
You could also use a humidity trend rather than a fixed value.
For example, if humidity normally sits at 50% and suddenly rises to 70% within a few minutes, that is a strong indication that someone has taken a shower.
Home Assistant can then react to the event rather than simply watching a number.
Detecting a water leak
This is where the humble bathroom becomes much more interesting.
A small water leak sensor placed near vulnerable plumbing can provide an early warning.
Typical locations include:
- Under the sink
- Behind the toilet
- Near exposed pipe connections
- Under a washing machine
- Near a water heater
- Near a bathtub or shower where appropriate
A leak sensor normally provides a simple binary state:
Dry
or
Water detected
That may not sound very sophisticated.
But it can become extremely useful when Home Assistant turns that information into an immediate response.
For example:
Water detected β send notification β turn off water supply if available β turn on bathroom lights β continue monitoring.
A smart water shut-off valve can make this even more powerful.
Home Assistant can then become the link between a small sensor on the floor and the home’s main water supply.
Obviously, automatic water shut-off should be designed carefully. A false positive should not leave the entire house without water because someone spilled a glass.
For critical plumbing protection, the reliability of the sensor and valve should be considered just as carefully as the automation itself.
What about the toilet itself?
Now we get to the fun part.
A toilet does not need to become a smart appliance to provide useful information.
There are several ways to detect unusual behaviour.
For example, a water flow sensor can reveal that water is being used when nobody should be using it.
If the home’s normal water usage is close to zero overnight but the water meter suddenly shows continuous consumption, something may be wrong.
A toilet with a faulty fill valve can produce exactly this kind of behaviour.
Home Assistant does not necessarily need to know:
“The toilet is leaking.”
It only needs to know:
“Something is using water when nobody is supposed to be using water.”
That is often enough to trigger an investigation.
Water monitoring becomes even more powerful
If you have access to water consumption data, Home Assistant can turn it into a useful dashboard.
You could track:
- Current water flow
- Daily consumption
- Weekly consumption
- Monthly consumption
- Unusual overnight consumption
- Water consumption while nobody is home
The same principle used for electricity monitoring can be applied here.
With electricity, we often ask:
How many kWh did the house use today?
With water, we can ask:
How much water did the house use today?
And then the more interesting question:
Why?
If your water meter provides suitable data, Home Assistant can help establish a baseline for normal household consumption.
That baseline can then be used to detect unusual behaviour.
Don’t forget hot water
Water consumption also has an energy component.
Heating water requires energy, so hot-water usage can indirectly affect electricity consumption.
If you have an energy monitor and a suitable water-heating system, you can potentially compare:
- Electricity consumption
- Hot-water usage
- Time of day
- Electricity prices
- Household occupancy
For example, a household might use considerably more electricity during the morning because of showers, hot water and heating.
That becomes particularly interesting when combined with dynamic electricity prices.
Home Assistant could show both:
Electricity
12.4 kWh today
and:
Water
XXX litres today
The numbers themselves are useful.
The patterns are even more useful.
A bathroom can also be occupancy-aware
Motion and occupancy sensors can make bathroom automation considerably more pleasant.
A basic motion sensor can turn the lights on.
An occupancy sensor can potentially do more.
For example:
- Someone enters β lights on
- Nobody detected β lights off after a delay
- Night-time β use low brightness
- Morning β use normal brightness
- Bathroom occupied β keep ventilation running
- Bathroom empty β start the ventilation cooldown period
This avoids one of the classic smart-home problems:
The light turns off while you are still in the shower.
Nobody wants that level of automation.
A useful combined automation
The real power appears when we combine several sensors.
Imagine the following:
- Bathroom occupancy is detected.
- Humidity starts increasing.
- Home Assistant starts the ventilation fan.
- Someone leaves the bathroom.
- The fan continues running.
- Humidity falls below the target level.
- Home Assistant switches the fan off.
That is a much better automation than:
Turn the bathroom fan on at 07:30.
It responds to what is actually happening.
A simplified version could look like this:
alias: Bathroom - Shower Ventilation
description: Ventilate the bathroom after humidity rises
triggers:
- trigger: numeric_state
entity_id: sensor.bathroom_humidity
above: 70
actions:
- action: fan.turn_on
target:
entity_id: fan.bathroom
- wait_for_trigger:
- trigger: numeric_state
entity_id: sensor.bathroom_humidity
below: 60
- action: fan.turn_off
target:
entity_id: fan.bathroom
This is still deliberately simple, but it demonstrates the principle.
The automation is not tied to a particular time.
It reacts to the condition of the room.
What should you actually install?
You don’t need a bathroom full of sensors.
A sensible starting point would be:
Temperature and humidity sensor
Useful for monitoring comfort, humidity and ventilation.
Zigbee sensors are particularly convenient because they are generally battery powered and integrate well with Home Assistant.
Leak sensor
Place one in a location where a leak would be detected early.
Behind or beside the toilet can be a good candidate, depending on the plumbing arrangement.
Motion or occupancy sensor
Useful for lighting and determining whether the bathroom is actually being used.
Smart ventilation control
If your ventilation system supports it, giving Home Assistant control can make humidity-based automation possible.
Water meter integration
This is the most advanced option, but potentially one of the most useful.
Depending on the meter and installation, you may be able to bring water consumption data into Home Assistant.
Don’t automate blindly
There is an important lesson hidden behind all of this.
A sensor does not automatically make a system smart.
You could install ten sensors in your bathroom and still have a terrible automation system.
The useful approach is to start with a question:
What problem am I trying to solve?
For example:
“I want to know if the bathroom stays humid for too long.”
Install a humidity sensor.
Or:
“I want to know if water is leaking behind the toilet.”
Install a leak sensor.
Or:
“I want to reduce unnecessary ventilation.”
Measure humidity and automate the fan.
This keeps the smart home useful instead of turning it into an expensive collection of gadgets looking for a purpose.
World Toilet Day is actually a good reminder
World Toilet Day may sound like one of the strangest occasions on the calendar for a Home Assistant article.
But the underlying topic is surprisingly relevant.
Water is something most of us take for granted.
We open a tap, flush a toilet or take a shower, and clean water simply appears.
The smart home can help us become a little more aware of what happens behind the scenes.
A leak sensor can detect a problem before you notice water on the floor.
A humidity sensor can tell you when a bathroom needs ventilation.
A water meter can reveal unusual consumption.
An energy monitor can show the electricity required to heat that water.
And Home Assistant can bring all of those pieces together.
So perhaps the lesson from World Toilet Day is not that your toilet needs to become smart.
It is that the infrastructure around your home deserves a little more attention.
And if Home Assistant can help you discover a leaking toilet before it becomes a flooded bathroom, that is probably one automation worth having.
Just don’t expect it to make cleaning the bathroom any more enjoyable.
Unfortunately, there is no integration for that.
Some of the links in this article are "affiliate links", a link with a special tracking code. This means if you click on an affiliate link and purchase the item, we will receive an affiliate commission. The price of the item is the same whether it is an affiliate link or not. Regardless, we only recommend products or services we believe will add value to our readers. By using the affiliate links, you are helping support our Website, and we genuinely appreciate your support.
