Background
I killed three plants in one month. All three died the same way — I either forgot to water them or watered too much.
This project solved that. It's been running for four months without a single plant death. The ESP32 monitors soil moisture every 5 minutes, triggers the pump when the soil gets too dry, and sends data to Home Assistant so I can check soil levels from my phone.
Components
6 itemsNeed these parts? Get this build sheet by email
Parts list with buy links, plus new builds as they're published. By subscribing you agree to our Privacy Policy. Unsubscribe anytime.
Why Capacitive Over Resistive?
Resistive moisture sensors corrode within weeks due to electrolysis. Capacitive sensors measure the dielectric constant of soil — no metal contacts in the soil, no corrosion. They last years.
Wiring
| Sensor Pin | ESP32 |
|---|---|
| VCC | 3.3V |
| GND | GND |
| AOUT | GPIO34 (ADC) |
| Relay Pin | ESP32 |
|---|---|
| IN | GPIO26 |
| VCC | 5V (VIN) |
| GND | GND |
Home Assistant Configuration
Add to your configuration.yaml:
mqtt:
sensor:
- name: "Plant Moisture"
state_topic: "solderhub/plant/moisture"
unit_of_measurement: "%"
icon: mdi:water-percent
switch:
- name: "Plant Pump"
state_topic: "solderhub/plant/pump"
payload_on: "ON"
payload_off: "OFF"
