Perhaps you are a blockchain developer and are trying to configure a network connectivity problem when a particular program must test whether its port is available. What if you have to ensure that your NAS device is discoverable by your Window 10 PC? Regardless of the reason which led you to search through open ports this article will guide you in checking it on Windows 10 using several tools which can be built in or downloaded for free.
The two programs that are available in Windows to easily find open ports are: Below I will show you how to do so on NetStat, PortQry.exe, and NirSoft CurrPorts.
Using NetStat to Check for Open Ports in Windows 10
Another way of confirming open ports is by using NetStat.exe which is actually NetStat for Windows 9x/Me/NT/2K/XP. For people using Windows 10, this tool is located in the System32 directory. This allowed me to examine open or connection/usage ports with NetStat.
Actually, the term netstat is a shorten form of network statistics. It shows TCP and IP connection status and protocol statistics. Open ports in the netstat commandline were printed when the -ab and -aon commands were included.
Here is the detail explanation of the letters from all the commands:
- “a” show all connection and Listen Port.
- Each listening port is generated with all the executives shown by “b”.
- The owning process ID linked to each connection is indicated by “o.”
- The ‘n’ form indicates the addresses and the port numbers as numbers.
There are actually two commands that should come in handy depending on the situation. The second option netstat-aon contains extra information with the process ID you can look up in the Task Manager later.
Using ‘netstat -ab’ to Identify Open Ports
The first option you will use (netstat -ab) displays all the ports currently being used and what process is using the port.
- In the Cortana Search Bar, type the following: cmd then right click and select, run as administrator.
- Now, type netstat -ab, then hit Enter.
- Wait for the results to load. Next to every local IP address, port names are get listed.
- Try to find your port number that you wished to find; if in st
- ate column it shows LISTENING then it is port is open.
Using ‘netstat -aon‘ to Identify Open Ports
The second option (netstat -aon) displays process IDs with which you will determine a task/application in the Task Manager. There are some processes that may not show up easily while using netstat -ab; this is why we get to use netstat -aon. As mentioned earlier “a” stands for connection or port in any form, “o” stands for owning process identity and “n” for addresses /port numbers as numerics.
When you want to know which program has a certain port locked up netstat -ab may not help, but netstat -aon is quite handy. In that case, follow these steps:
- With the Cortana Search Bar, enter “cmd“ then right-click and click on ‘Run as administrator.”
- Once inside, type the following command without quotes: type the string of characters netstat -aon then press Enter.
- You will now see five columns: Local Protocol, Local Address, Foreign Address, State, and Process ID. However, you may find the port number in the Local Address.. For example: 0.0.0.0:135. Here, 135 is the port number.
- Under the “State” column it will indicate if the corresponding port is open. For opened ports it will indicate LISTENING.
- It becomes certain that the specific port is used by which app by identifying the PID for a given port from the last column.
- By using the keyboard shortcut, Ctrl + Shift + Esc, open the Task Manager.
- The processes you can view depend on the system configurations, but you can find them all either under Details or Services tab. They will be listed according to the PID column to check the PID for the particular port that needs to be troubleshoot. Description section will also inform you which app uses the given port.
Checking for Open Ports using NirSoft called CurrPorts
While some people may find the Command Prompt solution hard to understand, there’s an easier way called NirSoft CurrPorts. This tool shows the list of your opened ports TCP/IP and UDP that you have opened now. You will also notice details related to a certain process, title, direction, version info and so on.
This tool was released sometime ago and the current version is compatible with Windows 10. The NirSoft Currports download link can be obtained from the Nirsoft home page at the bottom of the website.
Note: For the best experience make sure you download the right version. There is 32 and 64-bit versions available. The app is portable.After extracting the folder, run the executable file.
After CurrPorts is up and running, take the following actions:
- You will now see a list of processes of your computer. Arrange them according to Local Port so that you can retrieve them easily.
- It is now possible to locate and choose the particular port that is under concern.
- You can nowiated all the process details including the Process Name, Process ID, State, etc.
- The other one is to double click the process so that the details appear on a single window only.
Checking for Open Ports Using PortQry.exe
PortQry.exe is another program which has capability to scan open ports. You get PortQry (look for it down the page to download it) and unzip it to run it from the command line. However, if you do not wish to work through the command line there is PortQryUI, a Graphical User Interface (GUI) for PortQry which can also be downloaded as an add-on.
Using portqry.exe you type in the corresponding parameters which can be found in the folder of the executable file.
How to Run PortQry.exe Using the Command Prompt
- To download PortQry, follow the link from the Glass Ware website, and save it to the location of your choosing; once downloaded, extract the files from the PortableApps Zip format. The default is “C: It has a name that can be changed if necessary, and it is distinct from the organization\’s\ AI.
- If in the default directory, type cd c:Type the path of the executable file into the \PortQryV2\ entering in the Command Prompt.
- If in a custom directory, type cd [drive letter]:this structure became [folder1][folder2]\ but with actual names in the square bracket replaced by real names . Include all folders needed.
- To start the portqry tool you type portqry.exe -local at a command line. This command shows the TCP and UDP ports this specified ‘localhost’ uses.
- The output of Portqry also gives you several port mapping and the number of ports in Each state though does not display all the parameters that NetStat does.
- You can also look for open ports for a remote host. Portqry.exe should be run in the command prompt format of portqry.exe -n and the hostname or the IP address that pertains to the suspect application .
- Insert the specific name of the remote host in the hostname section and replace the IP section by the remote party’s IP address. To search for a particular port, include -e [port_number] to the command line.
How to Run PortQry.exe using the UI Add-On
However, there is an additional version of this utility named PortQryUI, created for those who would rather work with a graphical interface than commands.
PortQryUI add-on is already equipped with the required version of PortQry to perform its functions, so you do not have to download the two separately to utilise the application.
- Go to PortQryUI download page and save the program, after that, extract all the files to the directory you want. The default is “C:The name \”Second debate: Confusing \”Learning from Experience Demands_ it\” but one can change if one wants.
- Go to the Start then run the Windows Explorer, locate the above file then double click on it to open the PortQryUI.exe.
- If you want to see TCP and UDP for ‘localhost’ (it means your PC), you leave the destination IP at 127.0.0.1, that will scan the network devices an settings (like the card, router, etc.) as well the settings in your computer.
- Go to Manually input inquiry ports and enter 1-65535 in the fields below Ports to examine all TCP and UDP ports.
- Also from the Protocol, you can choose between TCP, UDP or Both.
- For filtering of your TCP/UDP ports list, click on Query predefined service, in the option, choose the service to query. It only selects one at a time.
- The same server can also be tested by simply changing the FQDN or domain in the foil box located at the top of the page.
- To check a particular port, enter the number in Ports to check query.
Last but not least, it is useful to know how to test whether some or another desired port is open if you are troubleshooting the network connection of a particular program or, for example, use a specific port for a game. Thank God it is not as hard to do as it appears to be on the video.
From the options shown above, Netstat is recommended most because it is part of the operating system and often provides all the information you need. It may need only a few more keystrokes than the CurrPorts, but there is no download necessary and no way to goof it up .