TOOL TUTORIAL · Network Communication & Troubleshooting

How to install and use Netcat

Netcat, often referred to as "nc," is a versatile networking utility that reads and writes data across network connections using TCP or UDP. Known as the "Swiss Army knife" of networking, Netcat is used for a variety of network-related tasks such as port scanning, transferring f…

Quick install: sudo apt install netcat-traditional

Installation steps

  1. Update your package list with sudo apt update
  2. Install with the apt command above for the traditional build
  3. Or install the openbsd build with sudo apt install netcat-openbsd
  4. Check it works by running nc -h to see the options
  5. Test a listener and client between two local terminals

See the full Netcat reference →