How to Check Open Ports on Windows
View listening ports and active connections using built-in Windows commands.
Before you start
Step-by-step instructions
1. Open Command Prompt
Open Command Prompt and prepare to inspect Windows network activity.
Open the Start menu, type cmd, and launch Command Prompt.
2. View ports and connections with netstat
Run the following command to show active connections, listening ports, numeric addresses, and PIDs.
netstat -ano
It shows the local port, remote connection information, connection state, and the PID of the process involved.
3. Filter by a specific port
If you only care about one port, filter the output so the result is easier to read.
netstat -ano | findstr :8080
Replace 8080 with the port number you want to inspect.
4. Identify the PID using the port
The last column in the netstat output is the PID. This tells you which process is using that port.
If the state shows LISTENING, the program is waiting for connections on that port.
5. Match the PID to a process name
Once you have the PID, you can match it to the actual process name.
tasklist | findstr 1234
Change 1234 to the real PID shown in your netstat result.
6. Close the process if needed
If the wrong process is blocking your port, you can close it after confirming it is safe to do so.
taskkill /PID 1234 /F
Do not force close system-critical or business-critical processes unless you are sure they are safe to stop.
Common reasons to check open ports
Another program may already be using the required port.
netstat helps verify whether the expected port is actually open and waiting for connections.
Reviewing active ports can help you understand which apps are communicating or listening in the background.
About this guide
This guide shows how to check open ports and active connections on Windows using built-in command line tools. It is useful when a program will not start, a port may already be in use, or you want to confirm whether a service is listening correctly.
How to follow this guide
- Open Command Prompt.
- Use netstat to view listening ports and active connections.
- Filter the results by port number if needed.
- Identify the PID attached to the port.
- Use Task Manager or taskkill if you need to inspect or close the related process.
Why use this method?
Checking open ports helps you understand which applications are listening for connections and whether a port conflict is blocking your software. It is useful for both everyday troubleshooting and more technical support work.
Frequently Asked Questions
What is an open port?
It is a network port that a program or service is using to listen for or maintain network connections.
Why would I check open ports on Windows?
You may need to check them when an app cannot start, a port is already in use, or you want to verify a local service is listening properly.
What is PID in netstat output?
PID means Process ID, which identifies the running process using the port.
Do I need extra software?
No. Windows includes netstat and related tools by default.