Wireshark can open and explore PCAP files, but the real magic is understanding what you’re seeing and why it matters.

Let’s say you’ve captured some network traffic using tcpdump on a server and now you have a file named capture.pcap. You fire up Wireshark and double-click capture.pcap.

The first thing you’ll notice is a list of packets, each with a timestamp, source and destination IP addresses, protocol, and a brief summary. It looks like a lot, but it’s just raw data.

Here’s a live example. Imagine we’re trying to debug a slow web request. We’ve captured traffic on the client machine while accessing example.com.

    1   0.000000    192.168.1.100 -> 104.18.32.102 TCP 66 51000 -> 443 [SYN] Seq=0 Win=29200 MSS=1460 SACK_PERM=1 TSval=1234567 TSecr=0 WS=128
    2   0.000050    104.18.32.102 -> 192.168.1.100 TCP 66 443 -> 51000 [SYN, ACK] Seq=0 Ack=1 Win=27900 MSS=1460 SACK_PERM=1 TSval=87654321 TSecr=1234567 WS=128
    3   0.000100    192.168.1.100 -> 104.18.32.102 TCP 150 51000 -> 443 [ACK] Seq=1 Ack=1 Win=29200 MSS=1460 SACK_PERM=1 TSval=1234570 TSecr=87654321 WS=128
    4   0.000500    192.168.1.100 -> 104.18.32.102 TLSv1.2 388 Client Hello
    5   0.050000    104.18.32.102 -> 192.168.1.100 TCP 222 Server Hello, Certificate, Certificate Request, Server Key Exchange, ...
    6   0.050100    192.168.1.100 -> 104.18.32.102 TCP 142 [ACK] ...
    7   0.050200    192.168.1.100 -> 104.18.32.102 HTTP 240 GET / HTTP/1.1
    8   0.100000    104.18.32.102 -> 192.168.1.100 TCP 142 [ACK] ...
    9   0.150000    104.18.32.102 -> 192.168.1.100 TLSv1.2 1500 Application Data
   10   0.150100    192.168.1.100 -> 104.18.32.102 TCP 66 [ACK] ...
   11   0.200000    104.18.32.102 -> 192.168.1.100 TLSv1.2 1500 Application Data
   12   0.200100    192.168.1.100 -> 104.18.32.102 TCP 66 [ACK] ...

This is a simplified view of a TLS handshake followed by an HTTP GET request.

  • Packets 1-3: The TCP three-way handshake. SYN from client, SYN, ACK from server, ACK from client. This establishes the connection. Notice the timestamps incrementing.
  • Packet 4: The client sends a Client Hello to start the TLS negotiation.
  • Packet 5: The server responds with its Server Hello and certificate.
  • Packet 6: Client acknowledges the server’s TLS messages.
  • Packet 7: The client finally sends the GET / HTTP/1.1 request over the established and secured connection.
  • Packets 8-12: The server starts sending back the HTML content (as Application Data within TLS). Notice the delays between packets 7 and 9, and 9 and 11. This is where latency might be hiding.

Wireshark’s power comes from its ability to dissect these packets. When you click on a packet, the bottom pane shows its layers: Ethernet, IP, TCP, TLS, and finally HTTP. You can expand each layer to see the raw bytes and decoded fields.

The core problem Wireshark solves is making opaque network protocols visible. Instead of just knowing "the website was slow," you can see exactly when each piece of data was sent and received, and identify delays.

Here’s how to build a mental model:

  1. The Network as a Series of Pipes: Each packet is a tiny message, and the network is a complex system of pipes. Your job is to see the flow of these messages.
  2. Protocols as Languages: IP is the addressing system, TCP is the reliable delivery service (ensuring messages arrive in order and without loss), and HTTP is the language for web requests. TLS encrypts and secures that language.
  3. Timestamps are Your Clock: The time difference between packets reveals latency, retransmissions, and processing delays.

The Problem: Understanding what a "TCP Retransmission" flag actually means in a PCAP is crucial for debugging.

The Wireshark View: You’ll see a packet with a [TCP Retransmission] flag in the summary line, and if you look at the TCP layer in the details pane, you’ll see the same sequence number and data being sent again.

The Mechanic: TCP uses sequence numbers to track data. If the sender doesn’t receive an ACK (acknowledgment) for a specific sequence number within a certain timeout period, it assumes the packet was lost and retransmits it. This is a fundamental part of TCP’s reliability but can indicate network congestion or packet loss.

The Fix: Often, a retransmission isn’t a Wireshark problem, but a symptom of a broader network issue. If you see frequent retransmissions, you’d investigate network health: check for packet loss (ping -c 100 <destination>) or high latency. The fix is usually external to the client or server running Wireshark.

The next thing you’ll want to master is Wireshark’s filtering capabilities to narrow down your analysis.

Want structured learning?

Take the full Wireshark course →