Urban centers worldwide continue to face challenges in traffic management due to outdated traffic signal infrastructure. This study aims to develop an intelligent traffic management system by implementing the Mask Regions-Convolutional Neural Network (MR-CNN) algorithm for real-time vehicle detection and traffic flow optimization. Utilizing the CRISP-DM framework, this research processes CCTV footage from the Pasteur-Pasopati intersection in Bandung to identify and quantify vehicles dynamically. The proposed system leverages an enhanced Mask R-CNN model with a ResNet-50 FPN backbone to improve detection accuracy. Experimental results demonstrate an 80% vehicle detection accuracy, with a macro-average precision of 0.89, recall of 0.83, and an F1-score of 0.82. These findings highlight the system’s capability to replace conventional fixed-time traffic signals with a more adaptive approach, adjusting green light durations based on real-time traffic density. The proposed solution has significant practical implications for reducing congestion and improving traffic flow efficiency in urban environments.