How To Use Netstat Command To Check Ports And Connections
Netstat helps you view active connections, open ports, and running network services. This guide explains how to run Netstat, read its output, and use the most helpful switches.
Table of contents
What Is Netstat And Why It Matters?
Netstat shows active TCP and UDP connections, listening ports, and routing tables. It helps you troubleshoot unknown connections, slow apps, and high network usage.
How To Run Netstat On Windows
Follow these steps to open Netstat from the command line.
- Open Start and type cmd.
- Select Command Prompt.
- Run netstat to display basic connection information.
If you get errors about the command not working, check this guide on fixing Netstat not recognized errors in Windows.
How To Check Active Network Connections
You can see every TCP and UDP connection on your system.
- Run netstat.
- Review Local Address and Foreign Address columns.

- Look at the State column to see if the connection is established or waiting.
How To Display All Listening Ports
Use a switch that shows all ports currently listening for traffic.
- Run netstat -a
- Look for entries marked as LISTENING.

- Identify apps bound to ports you want to investigate.
You can learn more in this detailed guide on checking listening ports with Netstat in Windows.
How To Show Running Processes That Use Each Port
You can match ports to specific processes for faster troubleshooting.
- Run netstat -ano.
- Note the PID in the last column.

- Open Task Manager and match the PID to the app using that port.
How To Check Protocol Statistics
Protocol stats help you identify dropped packets and connection issues.
- Run netstat -s.

- Review TCP and UDP sections for errors or resets.
- Compare values over time if you suspect network instability.
How To Watch Live Connection Changes
Netstat can refresh automatically to track changes.
- Run netstat -an 5.
- Let the command refresh every 5 seconds.
- Observe new or closing connections in real time.
If you also work with servers, you can check this useful guide on how to check ports in Windows Server.
Netstat Command FAQs
Netstat helps you inspect network activity, active connections, and open ports on your device.
Run netstat -ano and match the PID in the output with the same PID in Task Manager.
Yes, Netstat works the same on both Windows 10 and Windows 11.
Netstat cannot detect malware directly but it can reveal suspicious or unexpected remote connections.
Netstat gives you clear insight into your system network behavior and helps you troubleshoot blocked ports, slow apps, and suspicious activity. Once you learn the key switches, you can quickly spot problem connections and keep your Windows system more secure.
Read our disclosure page to find out how can you help Windows Report sustain the editorial team. Read more
User forum
0 messages