Before you start
This is a low-voltage project, and it should stay that way. Power it from batteries or a small, correctly rated supply, and keep all the electronics away from water. Plants mean watering cans and spills, so mount the board above the pot and keep the cable connections dry and out of reach of drips. If you solder, use eye protection and ventilation. Do not connect the project to mains equipment unless a qualified person has done the electrical work.
Why a sensor beats guessing
Most houseplants are lost to too much water as often as too little. A finger test on the surface can mislead, since the top of the soil can look dry while the root zone stays wet. A soil moisture sensor gives you a number that follows the soil’s wetness, so a reminder can fire when the reading crosses a threshold you chose, rather than on a fixed schedule. Different plants have different needs, so a number alone does not tell you what is right. Start with the guidance for each plant, then use the sensor to see how your pot behaves.
How soil moisture sensors work
Two common designs exist.
Resistive sensors pass a small current between two exposed metal probes. Wetter soil conducts better, so the resistance changes. They are cheap, but the probes tend to corrode over time because current flows through the soil, and the readings drift as they do. You can reduce this by powering the sensor only while you take a reading.
Capacitive sensors measure how the soil changes an electrical field, and they usually have coated probes with no exposed metal. They generally last longer and give steadier readings. Look for a model whose edges are sealed against moisture, since water getting into the board can ruin it.
Either type outputs a voltage, and your board reads it and converts it to a number. The exact range differs from one sensor to another, which is why you need to calibrate.
What you need
- A microcontroller board with an analog input. The choice of microcontroller boards is wide, and any basic one will do.
- A soil moisture sensor, preferably capacitive.
- A way to deliver the reminder: a small light, a buzzer, a display, or a message sent through your home network.
- A project power supply or battery pack, plus some wire and a breadboard for testing.
If you have not used an analog input before, voltage and current are the concepts to understand first, and a quick multimeter reading of the sensor’s output can confirm that it works.
The build in stages
- Connect and read. Wire the sensor to power, ground and an analog input, and print the raw readings.
- Calibrate. Record the reading with the sensor in dry air, then in a cup of water (up to the line marked on the probe, not above it). These give you the two ends of the scale. Real soil will land somewhere between them.
- Watch real soil. Place the sensor in a pot of freshly watered soil and note the reading. Check back as the soil dries. Note how the reading looks when the plant starts to droop or when you would normally water.
- Set a threshold. Choose a reading that means “water soon.” Leave a margin, so the reminder does not fire at the first dip.
- Add the reminder. Light an indicator, sound a buzzer or send a message. Reminders that repeat endlessly get ignored, so trigger once and then wait until the reading shows that the plant has been watered.
- Make it durable. Move to a small case and protect the electronics from moisture.
Getting reliable readings
Soil is not uniform. Readings change with how firmly the soil is packed, with air gaps near the probe, with fertilizer salts and with temperature. Insert the sensor firmly and at the same depth each time, avoid pressing it against the pot wall, and compare changes rather than individual values.
Take readings only occasionally. A reading every few minutes is more than a houseplant needs, and a longer interval, such as once an hour, saves battery and reduces wear on the sensor. If your readings jump around, averaging several in a row smooths them out. If they behave strangely, circuit troubleshooting starts with power and ground connections, and floating inputs can cause random values if the sensor wire comes loose.
What this project does not do
A reminder tells you the soil is dry. It does not know the plant species, light level, season or how much water to give. Treat the sensor as a helpful second opinion. Automating the actual watering with a pump adds extra risk, including overflow and leaks, and is better left until the reminder has proved reliable. If you ever do, keep water far from electronics and think about what happens if the pump gets stuck on.
Extending it
Once it works, you can log readings to see how fast each pot dries, compare several plants or add a light sensor. A temperature and humidity monitor placed nearby gives context for why one pot dries faster in summer. Keep the setup small, label which sensor belongs to which plant, and write down your threshold values so you can reuse them.