How to Find Port Numbers in Windows 10

To find port numbers in Windows 10, open Command Prompt, type netstat -ano, and press Enter. The Local Address column shows each port after the colon, such as :8080. The PID column tells you which program is using it, which you can look up in Task Manager.

Applies to: Windows 10. Checked against Microsoft Learn on September 27, 2026.

See the ports in use with netstat

  1. Open Command Prompt. See how to open Command Prompt in Windows 10.
  2. Type netstat -ano and press Enter.
  3. Read the list:
  • Local Address: your PC’s address and port. 0.0.0.0:8080 means port 8080 on all network connections.
  • Foreign Address: the other computer and its port, for active connections.
  • State: LISTENING means a program is waiting for connections on that port. ESTABLISHED means a connection is open. To check from another PC whether that port accepts connections, use Telnet in Windows 10.
  • PID: the process ID of the program using the port.
Windows 10 Command Prompt showing netstat -ano output with port 8080 listening highlighted
Run netstat -ano (1). Port 8080 is listening, used by PID 4312 (2).

To see the program name directly, open Command Prompt as an administrator and run netstat -abno instead.

Match the PID to a program

  1. Open Task Manager with Ctrl + Shift + Esc. See how to open Task Manager in Windows 10.
  2. Select the Details tab.
  3. Find the number in the PID column.
Windows 10 Task Manager Details tab with the contosoapp.exe row and PID 4312 highlighted
PID 4312 belongs to contosoapp.exe (1).

Find one port or IP address

Add findstr to filter the list:

  • One port: netstat -ano | findstr :8080
  • Only listening ports: netstat -ano | findstr LISTENING
  • Connections to a certain IP address: netstat -ano | findstr 203.0.113.5

The number after the colon in each matching line is the port.

Use PowerShell

To list listening ports in PowerShell, run:

Get-NetTCPConnection -State Listen | Sort-Object LocalPort

The OwningProcess column is the PID.

More ways to see ports

  • Show program names directly: open Command Prompt as administrator and run netstat -ab. Each connection is followed by the name of the program using it. It can take a minute to finish.
  • UDP ports in PowerShell: run Get-NetUDPEndpoint to list UDP ports, which Get-NetTCPConnection doesn’t show.
  • Resource Monitor: press Windows logo key + R, type resmon, and press Enter. On the Network tab, Listening Ports shows each port, its program, and whether the firewall allows it.

Common problems

  • “The requested operation requires elevation.” The -b option needs an administrator Command Prompt. Right-click Command Prompt and select Run as administrator.
  • The PID is 4. That’s the System process. Windows services such as file sharing and the built-in web server driver use it, so the port belongs to Windows.
  • An app says its port is already in use. Find the port with netstat -ano | findstr :port, look up the PID in Task Manager, and close that program, or change the port in your app’s settings.
  • You want to test a port on another computer. In PowerShell, run Test-NetConnection -ComputerName server -Port 443, using the computer’s name and port. TcpTestSucceeded : True means it’s reachable.

Frequently asked questions

What’s my IP address?

See how to find your IP address in Windows 10.

How do I open a port that’s blocked?

See how to open a port in Windows 10.

What are common port numbers?

Some well-known ones are 80 (HTTP), 443 (HTTPS), and 3389 (Remote Desktop). Apps often use their own numbers, so check the app’s instructions.

What’s the difference between TCP and UDP ports?

TCP connections check that every piece of data arrives, so web browsing, email, and file transfers use them. UDP is faster but skips those checks, so games, video calls, and DNS often use it. The same port number can be used separately by TCP and UDP.

Is it safe to have open ports?

Ports that Windows and your apps open are normal. What matters is whether they’re reachable from the internet. Your router and Windows Firewall block most outside connections unless you set up port forwarding.

Can I see which ports a website uses?

Websites almost always use 443 for HTTPS. In netstat, connections to a website show the site’s address with :443 in the Foreign Address column.

For serial ports like COM3, see how to check COM ports in Windows 10.

Microsoft’s references are netstat and Get-NetTCPConnection. More help is on our Windows Help & Guides page.

Related: How to open ports on Windows 11.

Related: how to enable SSH in Windows 10.

Related: how to enable FTP in Windows 10.

Get Our Free Newsletter

How-to guides and tech deals

You may opt out at any time.
Read our Privacy Policy