Menu
Dashboard Tutorials Upload
Account Timers
Settings
Tools · Beginner · 10 min read

Installing Wireshark — Complete Setup Guide

Install TShark (CLI) and Wireshark (GUI), capture your first packets, and understand the difference between the two tools. Covers NetHunter and Kali Linux.

Your progress 0%
01

What is Wireshark?

Network cables and packet flow infrastructure
Wireshark sits between your network interface and your analysis workflow — capturing every packet that passes through

Wireshark is the world's most widely used network protocol analyser. It lets you capture and inspect network traffic in real time, down to the individual packet level. Security professionals use it for traffic analysis, debugging, and understanding network behaviour.

Two tools, one engine
Wireshark and TShark share the same underlying packet capture engine (libpcap/npcap). TShark is the terminal/CLI version — ideal for NetHunter, headless Kali, and scripting. Wireshark is the full graphical interface — requires a desktop environment, KEX, or a VNC session on Android.
02

Installing TShark — CLI

TShark is the command-line packet analyser. It runs anywhere Wireshark's engine is supported — including NetHunter and headless Kali — with no desktop required.

bash
$ sudo apt update
$ sudo apt install tshark -y
Non-root capture prompt
During install, a dialog asks "Should non-superusers be able to capture packets?" — select Yes to allow your user to capture without sudo every time.
bash
$ sudo apt update
$ sudo apt install tshark -y
bash
$ sudo pacman -S wireshark-cli

Verify TShark installed correctly and check its version:

bash
$ tshark --version
TShark (Wireshark) 4.2.2 (Git commit xxxxxxxx).
Copyright 1998-2024 Gerald Combs <gerald@wireshark.org> and contributors.
Running on Linux 6.1.0-kali9-amd64

To run a basic capture on your default interface, simply type:

bash
$ tshark
Capturing on 'eth0'
    1 0.000000000 192.168.1.10 → 8.8.8.8      DNS 74 Standard query A example.com
    2 0.012453000      8.8.8.8 → 192.168.1.10 DNS 90 Standard query response …
03

Installing Wireshark — GUI

Desktop environment required
Wireshark's graphical interface requires a running desktop. On NetHunter or Kali for Android, launch a desktop session first via KEX (kex &) or a VNC client before starting Wireshark. On a standard Kali install with a desktop, just run it directly.
bash
$ sudo apt update
$ sudo apt install wireshark -y
bash
$ sudo apt update
$ sudo apt install wireshark -y
bash
$ sudo pacman -S wireshark-qt

Once installed, launch the GUI from your desktop session or from a terminal inside KEX / VNC:

bash
$ wireshark
04

Setting Up Capture Permissions

By default, capturing packets requires root. To allow your normal user to capture without sudo on every launch, add yourself to the wireshark group.

bash
$ sudo usermod -aG wireshark $USER
$ newgrp wireshark
Log out to apply
newgrp wireshark applies the group change to your current shell only. For it to apply system-wide, log out and log back in (or reboot). On NetHunter, restart your KEX/VNC session.

Alternatively, re-run the Debian configuration to toggle non-root capture via the interactive menu:

bash
$ sudo dpkg-reconfigure wireshark-common
05

Running Your First Capture

With both tools installed, try capturing some live traffic. Always capture only on networks you own or have explicit permission to monitor.

Legal reminder
Intercepting network traffic on networks you don't own or have written permission to test is illegal in most jurisdictions. Only capture on your own lab, your own hotspot, or an explicitly authorised target.
CLI — TShark

List your available network interfaces first, then start a capture on a specific one:

bash
$ tshark -D
1. eth0
2. wlan0
3. lo (Loopback)
4. any
bash
$ tshark -i wlan0 -c 50
Capturing on 'wlan0'
  1 0.000000 192.168.1.1  → 192.168.1.55  TCP 74 443→52341 [SYN, ACK]
  2 0.000122 192.168.1.55 → 192.168.1.1   TCP 66 52341→443 [ACK]
  …
Packets captured: 50
GUI — Wireshark
  1. Launch Wireshark from your desktop or wireshark in the KEX terminal
  2. Select your interface from the welcome screen (e.g. wlan0 or eth0)
  3. Click the blue shark-fin Start button — packets begin scrolling immediately
  4. Press the red Stop square when you have enough data
  5. Use the filter bar at the top to narrow results (e.g. http, dns, tcp.port == 443)
Common TShark flags
FlagWhat it does
-i eth0Capture on a specific interface
-DList all available interfaces
-c 100Stop after capturing 100 packets
-w out.pcapWrite capture to a file
-r file.pcapRead and analyse a saved capture
-Y "dns"Apply a display filter (same syntax as Wireshark)
-T fieldsOutput specific fields only (great for scripting)
06

Troubleshooting

Common issues and how to fix them on Kali and NetHunter.

tshark: command not found
TShark isn't installed or isn't on your PATH. Run sudo apt install tshark -y. On NetHunter, make sure you're in the Kali chroot session, not the Android base shell.
Permission denied on capture interface
Your user isn't in the wireshark group yet. Run sudo usermod -aG wireshark $USER then log out and back in. Or prefix with sudo tshark as a quick workaround.
Wireshark crashes or won't open (NetHunter / Android)
Wireshark needs a display. Start KEX first with kex & or connect your VNC client, then launch wireshark from within that session. Running it from a raw Android terminal without a display will fail.
No interfaces listed by tshark -D
The capture daemon can't see your interfaces without root. Run sudo tshark -D to confirm they exist, then fix permissions with the wireshark group method in section 4.