Portscan using PowerShell

28 October 2025 - Thomas Damgaard

How to test if a network port is reachable with PowerShell?

PS C:\Users\sdktda> Test-NetConnection -ComputerName example.com -port 80


ComputerName     : example.com
RemoteAddress    : 10.0.0.50
RemotePort       : 80
InterfaceAlias   : Ethernet 9
SourceAddress    : 10.0.0.2
TcpTestSucceeded : True
Filed under: howto, network, powershell, security, tips, windows

Back to article list