Learn how to build a DIY automatic plant watering system using Arduino, a capacitive soil moisture sensor, a relay module, and a mini pump. Includes full circuit diagram, code, and components list. Welcome to Poly Notes Hub, a leading destination for diploma and degree engineering notes.
Author Name: Arun Paul
Introduction
An Automatic Plant Watering System is a smart irrigation project that waters plants automatically when the soil becomes dry. This project uses an Arduino UNO, a soil moisture sensor, a relay module, and a small water pump.
It is very useful for home gardening, smart farming, and mini irrigation systems. The soil moisture sensor checks the moisture level in the soil continuously. When the soil becomes dry, Arduino turns ON the water pump automatically. Once the soil gets enough water, the pump turns OFF.
Components Required
Here in this table, we have listed the components with quantities that are going to be used on this project
| Sl No | Components | Quantity |
|---|---|---|
| 1 | Arduino UNO | 1 |
| 2 | Soil Moisture Sensor | 1 |
| 3 | Relay Module | 1 |
| 4 | Mini Water Pump | 1 |
| 5 | Connecting Wires | As Required |
| 6 | 5V Power Supply | 1 |
| 7 | Water Pipe | 1 |
Working Principle
The soil moisture sensor measures the moisture level of the soil.
- If the soil is dry:
- Sensor sends a signal to Arduino.
- Arduino activates the relay module.
- Relay turns ON the water pump.
- Water is supplied to the plant.
- If the soil is wet:
- Arduino turns OFF the relay.
- Water pump stops automatically.
This helps save water and keeps plants healthy.
Our Other Articles, Related to Arduino
📌 What is Arduino Nano? And its Pin Configuration
📌 What is Arduino Mega? Specifications and Pinout
Automatic Plant Watering System Using Arduino and Soil Moisture Sensor

Circuit Connections
Soil Moisture Sensor to Arduino
| Sensor Pin | Arduino Pin |
|---|---|
| VCC | 5V |
| GND | GND |
| AO | A0 |
Relay Module to Arduino
| Relay Pin | Arduino Pin |
|---|---|
| VCC | 5V |
| GND | GND |
| IN | D7 |
Water Pump Connection
- Pump Positive → Relay NO Terminal
- Pump Negative → Power Supply Negative
- Relay COM → Power Supply Positive
Arduino Code
Here is the full Arduino Code of the Automatic Plant Watering System Using Arduino and Soil Moisture Sensor –
int sensorPin = A0;
int relayPin = 7;
int moistureValue = 0;
int threshold = 500;
void setup() {
pinMode(relayPin, OUTPUT);
digitalWrite(relayPin, HIGH);
Serial.begin(9600);
}
void loop() {
moistureValue = analogRead(sensorPin);
Serial.println(moistureValue);
if (moistureValue > threshold) {
digitalWrite(relayPin, LOW);
Serial.println("Pump ON");
}
else {
digitalWrite(relayPin, HIGH);
Serial.println("Pump OFF");
}
delay(1000);
}Advantages of Automatic Plant Watering System
Here we have listed some advantages of the Automatic plant watering system with a soil moisture and Arduino board –
- Saves water
- Reduces human effort
- Maintains proper soil moisture
- Useful for smart agriculture
- Low-cost automation project
- Easy to build using Arduino
Applications of Automatic Plant Watering System
Here we have listed some applications of the Automatic plant watering with a soil moisture and Arduino board –
- Home gardening
- Smart irrigation systems
- Greenhouse monitoring
- Agricultural automation
- Indoor plant care systems
The Automatic Plant Watering System using Arduino is a simple and useful IoT-based project for beginners and students. It automatically controls watering based on soil moisture conditions and helps in efficient water management.
This project is perfect for Arduino beginners, diploma engineering students, and science exhibition projects.
This Article Can Search By These Keywords Also 👇
Automatic plant watering system, Arduino watering system, Soil moisture sensor project, Arduino UNO project, Smart irrigation system, Automatic irrigation using Arduino, Arduino soil moisture sensor, Water pump automation project, DIY plant watering system, Arduino agriculture project, Top 10 Arduino Projects For Beginners, Arduino Projects for Final Year Students, Top 10 Arduino Projects For College Students
