How to Configure Explicit Congestion Notification (ECN) in Windows 11 Using PowerShell

In traditional TCP/IP networking, network routers and intermediate switches manage congested packet queues through tail-drop mechanisms—meaning that when an internal buffer becomes full, incoming packets are dropped. While packet loss effectively informs the transmitting host to throttle its congestion window, it incurs severe latency penalties because the sender must wait for retransmission timeouts (RTO) or duplicate acknowledgements before resending data. Explicit Congestion Notification (ECN), defined in RFC 3168, is an extension to the Internet Protocol (IP) and TCP that allows intermediate routers to signal impending network congestion without dropping packets. This article demonstrates how to inspect, configure, and validate ECN capability across TCP transport settings in Windows 11 using PowerShell.

Understanding Explicit Congestion Notification (ECN) Architecture

ECN operates by utilizing two bits within the DiffServ field of the IPv4 header (or Traffic Class field in IPv6) and two flags within the TCP header:

  • ECN-Capable Transport (ECT): When establishing a TCP connection, the sender and receiver negotiate ECN support using the SYN/ACK handshake. If both endpoints agree, outbound data packets are marked with the ECT bit, signaling to intermediate routers that the connection supports proactive notification.
  • Congestion Experienced (CE): As packets traverse intermediate network hops, if an active queue management (AQM) router detects buffer saturation, it changes the ECT bit to the CE (Congestion Experienced) codepoint rather than discarding the packet.
  • Congestion Notification Feedback: When the receiver receives a packet with the CE bit set, it sets the ECN-Echo (ECE) flag in its TCP acknowledgement. Upon receiving this ACK, the sender reduces its transmission rate (halving its congestion window) as if packet loss had occurred, but without suffering the delay of dropped frames.
  • Reduced Jitter and Retransmissions: By preventing packet loss during congestion spikes, ECN dramatically lowers latency jitter, avoids head-of-line blocking, and ensures smooth real-time video streaming, gaming, and cloud data replication.

Inspecting Current ECN Configuration in Windows 11

To audit ECN support across your active Windows TCP/IP stack, launch an elevated Windows PowerShell console (Run as Administrator) and execute Get-NetTCPSetting:

Get-NetTCPSetting | Select-Object SettingName, EcnCapability, AutoTuningLevelLocal, CongestionProvider

To inspect the detailed parameters for the primary Internet transport profile, run:

Get-NetTCPSetting -SettingName "Internet" | Format-List SettingName, EcnCapability, AutoTuningLevelLocal, InitialCongestionWindowMss

Review the EcnCapability attribute. In standard Windows client installations, ECN is often set to Disabled by default due to historical compatibility concerns with outdated consumer routers.

Enabling Explicit Congestion Notification via Set-NetTCPSetting

On modern broadband, 5G cellular, enterprise WAN, and datacenter networks where modern routers and switches implement Active Queue Management (such as CoDel, FQ-CoDel, or RED), enabling ECN significantly improves network responsiveness.

To enable ECN for standard Internet traffic, execute Set-NetTCPSetting targeting the Internet profile:

Set-NetTCPSetting -SettingName "Internet" -EcnCapability Enabled

To enable ECN across all defined TCP profiles (including Datacenter, Compat, and Custom), pipe the query into the configuration cmdlet:

Get-NetTCPSetting | Set-NetTCPSetting -EcnCapability Enabled

Executing this command takes effect immediately for all newly established TCP connections without requiring a computer reboot or network adapter restart.

Disabling ECN for Network Troubleshooting

While modern networking hardware complies with RFC 3168, some legacy consumer broadband gateways, outdated hotel Wi-Fi portals, and misconfigured enterprise firewalls still drop packets carrying ECN bits, causing connection timeouts or slow website loading. If you encounter connectivity failures on specific legacy networks after enabling ECN, disable the feature:

Set-NetTCPSetting -SettingName "Internet" -EcnCapability Disabled

You can also inspect whether Windows scaling heuristics are dynamically altering your transport settings by querying Get-NetTCPSetting -SettingName "Internet" | Select-Object ScalingHeuristics.

Validating ECN Negotiation in Active Network Traffic

To confirm that your Windows 11 system is actively negotiating and transmitting ECN bits across live internet connections:

  1. Open PowerShell and verify that EcnCapability reports Enabled on the Internet profile.
  2. Establish a long-running download or video stream (e.g. streaming high-definition media or running a broadband speed test).
  3. Capture live traffic using a packet analyzer (such as Wireshark or netsh trace). Filter the packet stream for TCP SYN packets: tcp.flags.syn == 1.
  4. Inspect the TCP header flags. A correctly configured client sends SYN packets with both the ECE (ECN-Echo) and CWR (Congestion Window Reduced) flags set, signaling ECN readiness to the remote server.
  5. Examine subsequent data packets to verify that the IPv4 DiffServ field displays Explicit Congestion Notification: ECT(0) or ECT(1).

By enabling ECN capability via PowerShell, Windows 11 users and enterprise administrators can eliminate unnecessary packet loss during transient buffer congestion, achieving lower round-trip latency and consistent network throughput.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.