Six-Zone WiFi Sprinkler Controller with Web Interface
A 6-zone sprinkler controller with a local web interface for scheduling and manual control over home Wi-Fi.
Intermediate Project
— This is more than a simple dev-board project because it combines Wi-Fi web control, multiple switched outputs, and mains/24 VAC valve interfacing that requires careful power and isolation design.
Assumptions:
- The sprinkler valves are standard 24 VAC irrigation solenoids, one per station.
- The user wants a prototype that can be powered from mains via a low-voltage supply, not a battery-only system.
- The web page only needs to work on the local home network, not remote cloud access.
- No soil moisture sensing or weather integration was explicitly requested, so this is a controller-only design.
- The controller will be built as a custom PCB or wired prototype around a dev board, not as a finished outdoor-rated product.
Bill of Materials
Compatibility Notes
- The ESP32 GPIO is 3.3 V logic, so any relay board or transistor interface must be compatible with 3.3 V drive or include proper buffering.
- If the irrigation valves are 24 VAC, do not drive them directly from the ESP32; use the relay board to switch the valve supply.
- The IRM-20-12 provides 12 V DC, which is useful for the controller electronics and any intermediate relay circuitry, but it is not the same as the 24 VAC typically used by sprinkler valves.
- For a prototype, keep the ESP32 and low-voltage control circuitry isolated from the valve wiring to reduce noise and accidental damage.
You'll Also Need
- 6 valve connectors or terminal blocks for the station outputs
- Flyback/snubber protection strategy for the valve wiring if the relay board does not already include it
- Enclosure, cable glands, and strain relief for outdoor wiring
- PCB or perfboard, headers, hookup wire, and mounting hardware
- A 24 VAC transformer or valve supply if your sprinkler valves require standard irrigation AC power and you are not deriving it elsewhere
- Optional manual override buttons and status LEDs if you want local control without the web page
Estimated BOM Cost: $35-40 (based on live distributor pricing)
Design Considerations
Valve Switching Topology
Most irrigation valves are 24 VAC loads, so the safest prototype approach is to switch the AC line with relays rather than trying to drive the valves directly from the MCU. A relay board like 27115 simplifies wiring, but verify its contact rating and whether the board includes transistor drivers and flyback protection on the coil side. If you later move to a custom PCB, consider opto-isolated relay channels or triac-based AC switching for better noise immunity.
Power Architecture
The ESP32 board can be powered from USB for bench testing, but a fielded sprinkler controller usually wants a dedicated low-voltage supply. The IRM-20-12 is a reasonable starting point for a prototype, but if your valves need 24 VAC you will likely need a separate valve transformer or a different supply arrangement. Keep the logic supply and valve supply wiring physically separated to reduce conducted noise and accidental shorts.
Wi-Fi and Web UI Reliability
ESP32 is a good fit because it can host the web page locally and handle control logic without a separate network processor. For reliability, use a simple state machine and store the last known schedule in nonvolatile memory so the system recovers cleanly after a reboot. Add a watchdog and a default-safe valve-off state so a firmware crash does not leave a station energized.
Electrical Noise and Protection
Solenoid valves and relay coils can generate transients that reset the MCU or damage I/O if the layout is sloppy. Use proper decoupling near the ESP32 board, keep relay wiring away from the antenna area, and add suppression on the valve side if needed. In a custom design, plan for TVS diodes, snubbers, and a solid ground return path.
User Interface Scope
For a prototype, keep the web UI simple: manual on/off per station, run-time entry, and a basic schedule table. That is enough to validate the control concept without getting bogged down in calendar logic, weather integration, or account management. If you later add remote access, you will need authentication and a more careful security review.
Outdoor Deployment Risks
A sprinkler controller lives in a wet, electrically noisy environment, so enclosure and wiring quality matter as much as the electronics. Use a sealed enclosure, cable glands, and clearly labeled terminal blocks, and assume condensation will happen. Prototype indoors first with dummy loads or a test valve before connecting real irrigation wiring.
Want to customize this project or build something different?
Try the Project Advisor


