November 24, 2025

Are you still frustrated that you can’t monitor the water tank level?

This is an excellent and common application for automation. Here is a comprehensive guide to building a water tank level monitoring system using liquid level sensors.

Understanding the Core Concept

A water tank monitoring system operates by using a sensor to measure the water level and then converting that measurement into a readable signal (such as a percentage, volume, or a simple Full/Empty status). This signal can be displayed locally, transmitted to a cloud server, or used to trigger alarms and controls.

Part 1: Choosing the Right Liquid Level Sensor

The heart of your system is the sensor. The best choice depends on your budget, accuracy requirements, and the type of tank (e.g., underground, overhead, plastic, metal). Here are the most common types of sensors for this purpose:

1. Ultrasonic Sensors (Non-Contact)

   – How they work: Mounted at the top of the tank, they emit ultrasonic sound waves and measure the time it takes for the echo to return from the water’s surface.

   – Pros:

     • Non-contact, so they don’t touch the water (ideal for corrosive liquids or clean water tanks).

     • Easy to install.

     • Provide continuous level data.

   – Cons:

     • Can be affected by fog, steam, or heavy foam on the surface.

     • Slightly more expensive than some contact options.

   – Best for: Overhead tanks, sumps, and large storage tanks.

2. Pressure Transducers / Submersible Sensors

   – How they work: The sensor is submerged at the bottom of the tank. It measures the hydrostatic pressure exerted by the water column above it. The pressure is directly proportional to the height of the water.

   – Pros:

     • Highly accurate and reliable.

     • Unaffected by surface conditions like foam or turbulence.

     • Good for deep wells and boreholes.

   – Cons:

     • Needs to be compatible with the liquid.

     • Requires submersion, so installation can be more involved.

   – Best for: Wells, boreholes, deep industrial tanks.

3. Float Switches (Point-Level Detection)

   – How they work: A magnetic float moves up and down with the water level, activating a hermetically sealed reed switch at specific points (e.g., High Level and Low Level).

   – Pros:

     • Simple, rugged, and very low cost.

     • Excellent for simple on/off control (e.g., turning a pump on/off).

   – Cons:

     • Does not provide continuous level data—only alerts at preset points.

     • Mechanical parts can wear out or get stuck.

   – Best for: Simple pump control, high/low level alarms.

4. Optical Sensors

   – How they work: Utilize an infrared LED and a phototransistor. The presence or absence of liquid changes how the light is refracted, triggering a switch.

   – Pros:

     • Small, compact, and has no moving parts.

     • Fast response time.

   – Cons:

     • Typically used for point-level detection (full/empty), not continuous.

     • Can be fooled by bubbles or deposits on the sensor tip.

   – Best for: Small tanks, leak detection, coffee makers, and appliances.

5. Capacitive Sensors

   – How they work: Measure the change in capacitance between the sensor probe and the tank wall. The capacitance changes when the probe is covered by liquid versus air.

   – Pros:

     • Non-contact option available (sensor on the outside of the tank wall).

     • No moving parts, works with corrosive liquids.

   – Cons:

     • Can require calibration and can be affected by material buildup on the probe.

   – Best for: Chemical tanks, pressurized tanks, or where internal access is limited.

Part 2: Building the Complete Monitoring System

A sensor alone does not constitute a system. You need to process its signal and act on the data.

System Components:

1. Sensor: Your chosen level sensor (e.g., Ultrasonic).

2. Microcontroller / PLC: The “brain” that reads the sensor data.

   – Beginner/Hobbyist: Arduino, ESP32, or Raspberry Pi.

   – Industrial: Programmable Logic Controller (PLC).

3. Communication Module (Optional but Recommended):

   – ESP32 has built-in Wi-Fi.

   – GSM/GPRS Modules for areas without internet.

   – LoRaWAN or NB-IoT for long-range, low-power applications (e.g., remote tanks).

4. Output & Display:

   – Local Display: LCD screen, LED bar graph, or simple LEDs.

   – Alarms: Buzzer or flashing light for high/low levels.

   – Control: Relay module to automatically turn a water pump on or off.

5. Power Supply: Battery, solar, or mains power.

Data Flow & Logic:

Sensor -> Microcontroller -> Output & Cloud -> User

1. The sensor continuously measures the level.

2. The microcontroller reads this measurement (e.g., as a voltage, pulse, or digital value).

3. The microcontroller converts the reading into a useful unit (e.g., centimeters, liters, or percentage).

4. The system then:

   – Updates the local display.

   – Checks if the level is above a “High” threshold (stop pump) or below a “Low” threshold (start pump).

   – Sends the data to a cloud platform (like ThingSpeak, Ubidots, or a custom dashboard) via Wi-Fi/Cellular.

5. The user can see the level in real-time on a phone or computer and receive SMS/email alerts.

Part 3: Example System Architecture

Here’s a practical example using an Ultrasonic Sensor and an ESP32 for a smart home overhead tank.

Components:

• ESP32 Microcontroller

• HC-SR04 or JSN-SR04T (waterproof) Ultrasonic Sensor

• Relay Module

• Water Pump

• Breadboard & Jumper Wires

• Power Supply

How it Works:

1. The ultrasonic sensor is mounted on the top of the tank, pointing down at the water.

2. The ESP32 powers the sensor and reads the distance to the water surface.

3. It calculates the water level: Water Level = Total Tank Height – Distance to Water.

4. It converts this height into a percentage.

5. The ESP32 connects to your Wi-Fi and sends this percentage to a cloud dashboard.

6. Automation Logic: If the level falls below 20%, the ESP32 triggers the relay to turn ON the pump. If the level rises above 95%, it turns the pump OFF.

User Benefits:

• Real-time Monitoring: Check your water level from your phone anywhere in the world.

• Water Conservation: Prevents overflow and wastage.

• Convenience: Fully automatic pump control; no more running out of water.

Summary: Choosing Your Path

Your Goal | Recommended Sensor Type | Recommended Controller | Complexity

— | — | — | —

Simple Pump Control | Float Switch | Arduino + Relay | Low

DIY Smart Tank with App | Ultrasonic / Pressure | ESP32 | Medium

Industrial/Agricultural | Pressure Transducer / Ultrasonic | PLC / Industrial IoT Gateway | High

Chemical Tank | Capacitive / Non-Contact Ultrasonic | PLC | Medium-HighBy understanding the sensors and the system architecture, you can effectively design and build a water tank monitoring solution tailored to your specific needs.