Indian agriculture, the backbone of the country's economy, faces significant challenges due to climate change and crop diseases. Soil productivity is highly dependent on water availability and seasonal variations in India. In addition, environmental changes in neighboring regions also contribute to global warming. Climate variability intensifies the outbreaks of diseases, threatening food security. This research aims to enhance precision farming in India by proposing a smart agricultural framework using IoT (Internet of Things) sensors, advanced routing algorithms, machine learning (ML), and reinforcement learning (RL). With the help of environmental and crop-related data like soil moisture, temperature and humidity the framework can resourcefully utilize resources, improve yield, protect the climate, and ensure resiliency to climate change. Information such as temperature and crop health is measured by strategically positioned IoT sensors across farmlands and sent through the Bee Guided Routing Protocol (BGRP) and Energy Efficient Routing Protocol (EERP) for proper management of data flow. Farmers and agricultural specialists can make informed decisions due to the processing, storing, and computing capabilities offered by Cloud technologies, which facilitate easy access to data. The proposed hybrid Convolutional Neural Network–Lotus Leaf Optimization Algorithm (CNN-LLOA) refines and processes the dataset to improve prediction accuracy. Anomalies like insect and disease infestations, anomalies, and agricultural yield are predicted alongside the detection of crop conditions.