
Insert two metal probes into plant substrate with a spacing of about 2–3 cm. Connect them to a small transistor switching stage powered by 3V–9V DC. Electrical resistance between the probes drops as water content rises, which allows the transistor to drive an indicator such as an LED or buzzer.
Use corrosion-resistant electrodes made from stainless steel, brass, or galvanized nails. Length between 5 and 8 cm works well for most flower pots. The probes act as a variable resistor: dry substrate may show resistance above 200 kΩ, while wet conditions often fall below 20 kΩ.
A common layout includes an NPN transistor such as BC547 or 2N2222, one base resistor around 100 kΩ, and an LED with a 220–470 Ω current limiter. When water content drops, resistance between probes rises, base current decreases, and the indicator switches state to signal low water availability around the plant roots.
Mount the electronic parts on a small perforated board and keep the probe leads under 30 cm to reduce electrical noise. Power can come from two AA batteries or a small regulated supply. This compact arrangement allows continuous monitoring of plant substrate conditions inside pots, planters, or greenhouse trays.
Simple Soil Moisture Sensor Circuit Diagram With Probe and Transistor Connection

Insert two metal electrodes into plant substrate and connect them to the base control path of an NPN transistor such as BC547 or 2N2222. Electrical resistance between the probes changes with water content. This variation controls current flowing through the transistor and switches an LED indicator.
Keep the probe spacing between 20 and 30 mm. Greater distance increases resistance range but may slow response. Stainless steel rods or galvanized nails with length 50–80 mm resist corrosion inside plant containers.
Typical component set
- NPN transistor BC547 or 2N2222
- Base resistor 100 kΩ
- LED indicator
- Current limiting resistor 220–470 Ω
- Power supply 3V–9V DC
- Two metal electrodes
The electrode pair forms a variable resistance element. Dry substrate often measures above 150–300 kΩ. Wet conditions drop resistance below 20–40 kΩ. This change alters base current and drives the transistor between cutoff and conduction states.
Connect the electrodes in series with the base resistor. One electrode links to the positive supply through the resistor, while the second electrode connects to the transistor base terminal. The emitter connects to ground. The LED and its series resistor sit between the positive rail and the transistor collector.
Assembly steps
- Mount electronic parts on perforated board
- Attach the base resistor between supply rail and probe lead
- Connect transistor emitter to ground
- Install LED and series resistor at the collector path
- Route probe leads away from power traces
Maintain probe cable length below 30 cm. Longer leads can pick up interference from nearby power adapters or motors. Twisting the probe conductors together reduces noise.
Power the assembly with two AA batteries, a 5-volt regulator module, or a small USB supply. This arrangement monitors plant substrate conditions in pots, garden beds, or greenhouse trays and signals when water content drops below the chosen threshold.
Probe design and electrode spacing for a basic soil moisture sensor circuit

Use two corrosion-resistant metal rods placed 20–30 mm apart and inserted 50–80 mm into plant substrate. Stainless steel, brass, or galvanized nails work well because they resist oxidation while remaining conductive. Connect each rod to the measurement stage with short insulated leads.
Spacing between electrodes controls resistance range. Narrow gaps below 10 mm produce small resistance variation and weak detection signals. Distances above 40 mm may cause unstable readings because current spreads through a larger volume of substrate. A moderate separation around 25 mm provides stable electrical response across dry and wet conditions.
Mount the electrodes on a plastic strip or small PCB to keep alignment fixed. Leave only the lower metal portion exposed and cover the upper section with heat-shrink tubing to reduce corrosion at the contact point. Probe leads should remain shorter than 30 cm and routed away from power lines to avoid interference in the detection stage.