netstat
Classic network connection/route viewer.
KaliParrotLinuxpassive
pkg: net-tools
netstat shows connections, listening ports, routing tables and interface stats — still common despite ss superseding it.
Syntax
netstat [-tulpn]
Example
netstat -tulpn
Lists listening TCP/UDP ports with the owning programs.
Options & flags
What each switch does. Toggle them in the builder below to assemble a command.
Command builder
Tick options (and fill any values) to build a ready-to-copy command.
netstat
Usage examples
netstat -tulpn
Listening ports with owning programs.
netstat -rn
Show the kernel routing table.
Advantages
- Familiar and widely documented
- Connections + routes + stats
- On many legacy systems
Disadvantages
- Deprecated in favour of ss
- Slower on busy hosts
- May be absent by default now
Tags
#network#sockets
Official docs: netstat ↗
Related commands
Frequently asked questions
What is netstat used for?
netstat shows connections, listening ports, routing tables and interface stats — still common despite ss superseding it.
What is an example netstat command?
A common example is: netstat -tulpn — Lists listening TCP/UDP ports with the owning programs.
Is netstat part of Kali Linux?
Yes. netstat ships with Kali Linux (and Parrot OS). If missing, install it with: sudo apt install net-tools.
What category of security tool is netstat?
netstat is a Core Linux tool with a passive-risk profile when run against a live target.
Try recon tools live
Run real scans against a domain you control, stage by stage.