This document describes an automatic drip irrigation system using a programmable logic controller (PLC). The system aims to reduce water consumption in agriculture and increase crop productivity by automatically and precisely controlling the supply of water and fertilizers to crops. It uses soil moisture sensors to monitor soil moisture levels, which are fed as inputs to the PLC. The PLC then controls pumps and valves based on a programmed logic to water the crops only when the soil is dry. The system operates in two modes - timer mode and sensor mode - according to farmer convenience. It is found that such a system can help optimize water usage and reduce labor needs in agriculture.