Arduino Water Level Measurment




This is my arduino project for water level measurement and control the pump when the water level reaches below the minimum level so it open the pump control by a relay and stop the pump when water level reaches to its high point.

i also add liquid crystal 16X2 LCD which show level as bar graph and percentage also show the depth of water from the sensor in CM and the state of pump weather it is on or off and one more thing which is also help that is Ethernet shield which record the the data on a SD card as txt or excel file so that you can analyse your water consumption.

as i am new to arduino adn dont knows to much bout coding i wanna add a push button which can start the pump connected to the relay as mannual when the button push the pump start if it is off or turn off if it is on

there may some grammatic mistake for i am sorry

hardware required

  1. arduino
  2. ultrasonic sensor (HC-SR04)
  3. lcd 16X2 (i used i2c lcd)
  4. relay (5 V)
  5. breadboard
  6. jumper wired
  7. Ethernet shield (wiznet w5100)
  8. SD card

for wire connection


trigger pin connected to ardino pin 3

echo pin connected to ardino pin 2

GND pin connected to ardino pin ground

VCC pin connected to ardino 5V


SCL pin connected to ardino pin A5
SDA pin connected to ardino pin A4

GND pin connected to ardino pin ground
VCC pin connected to ardino 5V


RE1 pin connected to ardino pin 7

GND pin connected to ardino pin ground

VCC pin connected to ardino 5V


as i set the max level to 30 cm which you can adjust according to your water tank level when the water level goes to 30cm away from the sensor it which display 30 cm, 0 % and empty bar graph.

now when the water level reached to 25cm away from the sensor it will trigger the relay and start the pump which will inrease the water level in the tank and the water level goes high and upto 11 cm the will remain on when it reaches to 10 the water pump will stop.

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1:

Be the First to Share


    • Made with Math Contest

      Made with Math Contest
    • Multi-Discipline Contest

      Multi-Discipline Contest
    • Robotics Contest

      Robotics Contest

    8 Discussions


    3 years ago

    Can u made a schematic?


    4 years ago

    How can do this project on Arduino uno and 16*2 LCD display???


    4 years ago on Introduction


    I’m irinakim and I’m work in the Wiznet.

    Thank you for using our product.

    We are collecting so much data using our product.

    And I will post the this project on our Web site.(

    Can I post your product on our Web site?

    1 reply

    4 years ago

    Cool approach for water lever measuring, there are a lot of ways of doing it, but its unusual with distance sensors. I could help you if I can, If you find any problem post it and me or the community will try to help

    1 reply

    Reply 4 years ago on Introduction

    thanks for your appreciation

    i don't no to much arduino programming if you can add one push button which can manually turn on and off the water pump that will nice



    4 years ago

    Very nice I've been looking for a way to measure the water level in a rain barrel and this is easier than floats and much cheaper than capacitance sensors.