How to Find a Port Number

By Sam N. Austin

Computers communicate with the Internet by sending and receiving data through a network connection such as Ethernet or wireless. Different types of communications -- such as for websites, chat, or email -- are exchanged through designated ports, each having its own number. For example, website data might be exchanged at port 1031 and email data at port 25. The Windows 8 network statistics utility enumerates port information on a given computer so that you can find a port number and determine the type of data the computer is exchanging through the port.

Places to Look

Step 1

Check your program's documentation to find out what port it runs on.

Step 2

Check the " Service Name and Transport Protocol Port Number Registry" list on the IANA website to find out what port number the service or protocol runs on.

Step 3

Use Netstat. Click the Start button. Type "cmd" in the search box. Hold down "Shift" and "Ctrl" on the keyboard and then press "Enter."Click "Yes" in the dialog window. Type the following in the command prompt window:netstat -b -aExamine the list to find the port associated with the program or service for which you want the port number. Using netstat's "-b" option requires that you have Administrator permissions on your Windows 8 user account.

Use Netstat without Administrator Privileges

Step 1

Press "Ctrl," "Shift" and "Esc" simultaneously on your keyboard to bring up Task Manager.

Step 2

Right-click in the column header to reveal a pop-up list of column names. Select "PID" from the list to display the process ID.

Step 3

Type "cmd" in the Start menu search box. Press "Enter." Type "netstat -ano" at the command prompt. Find the PID you previously noted and see what port it's using.

Tips & Warnings

  • The directions provided apply only to netstat use in Windows XP. Different directions apply to nestat use in other operating systems.