Effective algorithms for queue management are crucial in place of guaranteeing maximum efficiency in gateway routers since network traffic continues to expand dramatically. An online researcher has suggested the Active Queue Management (AQM) strategy regarding the upcoming generation of gateway switches. The common active queue scheme remains (RED) Random Early Detection. Random early detection is susceptible to parameterization issues and lacks a self-adaptation mechanism. Several RED variants have been formed; nevertheless, variations in traffic load have an adverse effect on all of them. Due to the fact that each has a static drop pattern, to address the RED and its variation schemes, the SARED system, or the design of self-adaptive random early detection was created. But in order to prevent congestion, during the time when the queue length surpasses a present maximum threshold limit, SARED aggressively removes packets. This causes networks having a lot of traffic situations the average is expected to increase queue delay, so in those cases, SARED should be less aggressive. This paper develops a priority-based queuing congestion control method for IoT gateways to manage network congestion. Our method (priority-based algorithms) performs substantially better with regard to throughput, delay, and packet loss than the present methods of SARED. The outcomes of the conducted simulation experiments have shown that in scenarios with heavy traffic loads, priority-based self-adaptive random early detection (PSARED) has greatly decreased average queuing delay by 3%, minimized average throughput by 1%, and decreased the rate of packet loss by 10% in contrast to SARED.