Pcornel
Browse topics
Options
Recent
Favorites
Command · Windows / Windows Server / PowerShell

netstat -ano

netstat -ano

Lists all TCP and UDP connections and listening ports, with the process ID that owns each one.

Execution context

Standard user

Use when

You need to know which process listens on a port, or whether a connection is established.

Then verify

Identify the process with Get-Process -Id <pid> and test the port with Test-NetConnection -Port.

Privilege Standard userState impact Read-onlyProduction Unknown

Operational impact: Read-only.
Command detailsSafety model · family · platform · verification · bundle
PrivilegeStandard user
Execution contextStandard user
State impactRead-only
Safe during productionUnknown
CategoryNetwork Troubleshooting
Evidence levelmixed
Primary DomainWindows
Historical technical verificationNeeds verification dateCurrent command content requires review after a Git edit.
Family Etwork Roubleshooting
PlatformWindows / Windows Server / PowerShell
PrerequisiteStandard user
Output fields

Field glossary

Important fields projected from persisted Command guidance.

Proto, Local Address, Foreign Address, State, PID

Important persisted output field; use surrounding guidance for interpretation.

Command → Topic semantics

Used in these Topics

Each relation carries both placement role and operational semantic: verifies, configures, troubleshoots, collects evidence, changes state or general.

DomainsWindows

Find another Command

Reference enrichment

Evidence boundary

What this output can establish — and where you must not over-claim.

Proves

Shows the current sockets and the process ID behind each one.

Does not prove

Does not prove a firewall allows traffic to the listening port.

Next check

Identify the process with Get-Process -Id <pid> and test the port with Test-NetConnection -Port.

Depth when you need it

Command guidance

Execution context

Standard user

Use when

You need to know which process listens on a port, or whether a connection is established.

Important fields

Proto, Local Address, Foreign Address, State, PID

Common problems

port already in use by another process; many TIME_WAIT or SYN_SENT entries

Operational impact

Read-only.

Technical context

Match the PID with tasklist /fi "PID eq <pid>" or Get-Process -Id <pid>. Get-NetTCPConnection gives the same data in PowerShell.

Confirmation

Confirm action

Continue?