The practice of agriculture is heavily reliant on the implementation of irrigation systems. Technology improvements have made it unnecessary to rely on someone else to perform irrigation when we are out and whenever crops need to be watered. Many researchers have attempted to autonomously irrigate crops, but difficulties with accuracy, timing, and cost are rarely addressed and given top priority. The proposed approach employs a real-time sensor, wireless sensor network, the adaptive bacterial foraging optimization (ABFO) algorithm, and a fuzzy irrigation system control to achieve autonomous watering, thereby enabling smart irrigation. This method reduces waste while preserving the container’s water supply. Automated irrigation determines whether crops need to be watered by considering the type of crop, the weather, and the soil moisture and not soil moisture alone. The need for water is calculated using the three aforementioned criteria and fuzzy control drives the automation. Using an arduino-based IoT circuitry, the bioinspired model with algorithm adaptive bacterial foraging optimization, generates the optimized values for three parameters, which are then used by fuzzy logic control to predict the watering requirements of the plants. In terms of accuracy, timeliness, and cost, the suggested approach is advantageous. With this model, it is now possible to completely automate the irrigation system.