Urban flooding is a significant issue that affects many cities worldwide, often leading to waterlogging, traffic congestion, and accidents due to open manholes. Existing drainage systems struggle to efficiently manage excess rainwater, causing hazardous conditions for pedestrians and vehicles. This paper presents a novel Rain Operated Manhole Control System that automatically detects rainfall and adjusts the manhole cover accordingly. Using IoT sensors, rain detectors, and motorized manhole covers, the system prevents urban flooding by allowing excess water to drain effectively while ensuring pedestrian safety by automatically closing the manhole when the rain subsides. The proposed system is cost-effective, scalable, and easy to implement in urban drainage infrastructure. The integration of automation, AI-driven weather prediction, and cloud-based monitoring makes it a smart city solution for efficient stormwater management.