Test-NetConnection
SafePing + port reachability
Test-NetConnection <host> -Port <n>
Like ping plus TCP port reachability and trace in one cmdlet.
Examples
Test-NetConnection smtp.example.com -Port 587Check SMTP port reachability
Syntax
Test-NetConnection <host> [-Port n] [-TraceRoute]
Before you run it
Read-only.
Used when you see
OneDrive sync is stuck
2
See the whole flow →Test reachability to the sync endpointse.g. Test-NetConnection to the service endpoints on 443.
Related commands
- pingBasic reachability test
- Get-NetTCPConnectionPorts/connections in PS
The same reference, with no signal at all
Every command on this site, held on your device. The app adds 632 more: 1,510 commands and 120 fix flows, searchable with no connection. Free to install, no ads (some content is a one-time purchase).
Get it free on the App Store