Water scarcity and inefficient irrigation remain major challenges in sustainable agriculture. This paper presents a smart irrigation system that integrates DHT11, soil moisture, rain, and water level sensors with an ESP32 microcontroller and Random Forest Algorithm for data-driven irrigation control. Real-time data is transmitted to the ThingSpeak cloud for remote monitoring. The system achieved 62% precision in identifying irrigation needs and reduced manual intervention while conserving water. By optimizing water usage, lowering costs, and enhancing yield, the proposed system offers a scalable and eco-friendly solution for modern farming.