This paper aims to alleviate traffic congestion brought on by antiquated, ineffective traffic management systems that are based on a predefined countdown. Long red light delays are the result of these traditional systems, which have a predefined countdown regardless of the actual traffic on a given road. Our system makes sure that time set for the traffic lights reflects the traffic density in real time, which ensures efficient use of time. In order to do this, we first compute the traffic density, which is ascertained by combining image processing methods along with the use of ultrasonic sensors. The Raspberry Pi then processes this data and then manages the time set for the traffic light. Furthermore, the use of SQL Alchemy ensures that this processed information is stored to the cloud, where it may be utilized in events of sensor failure or system malfunction. Index Terms—Image Processing, Raspberry Pi, Traffic Congestion, Ultrasonic sensors