Display filter operators 21
English and C-like operator forms mean the same and can be mixed within one filter string.
| Shortcut | What it does |
|---|---|
ip.src == 10.0.0.5 | Equal toThe English form is eq; when a packet holds the field several times, one matching value is enough. |
ip.src != 10.0.0.5 | Not equal toAlso written ne; every occurrence of the field has to differ, the meaning it has had since Wireshark 3.6. |
ip.src === 10.0.0.5 | All values equalAlias all_eq: passes only when each occurrence of the field has that value. |
ip.src !== 10.0.0.5 | Any value not equalAlias any_ne: a single differing occurrence of the field is enough. |
frame.len > 10 | Greater thanThe English spelling is gt; integers may be given in decimal, octal, hexadecimal or binary. |
frame.len < 128 | Less thanWritten lt in the English form. |
frame.len ge 0x100 | Greater than or equalge is the English spelling of >=; the value here is hexadecimal. |
frame.len <= 0x20 | Less than or equalThe English spelling of this operator is le. |
sip.To contains "a1762" | Contains a valueSearches a protocol, field or slice for a string or byte sequence; there is no C-like symbol for it. |
http.host matches "acme\\.(org|com|net)" | Match a regular expressionA case-insensitive PCRE2 pattern; the tilde is the symbol form and backslashes are doubled inside a normal string. |
wsp.header.user_agent matches "(?-i)cldc" | Case-sensitive regex matchThe (?-i) prefix switches off the default case-insensitive matching. |
smb.path contains r"\\SERVER\SHARE" | Raw string literalAn r prefix makes each backslash literal, so none has to be doubled. |
ip.src==10.0.0.5 and tcp.flags.fin | Logical ANDThe C-like form is &&; a packet shows only when both tests are true. |
ip.src==10.0.0.5 or ip.src==192.1.1.1 | Logical ORThe C-like form is ||; and binds tighter than or, so add parentheses when mixing them. |
tr.dst[0:3] == 0.6.29 xor tr.src[0:3] == 0.6.29 | Logical XORThe C-like form is ^^; in precedence it sits between and and or. |
not llc | Logical NOTThe C-like form is !; this shows the packets in which the llc protocol does not exist. |
tcp.port in {80, 443, 8080} | Set membershipSame result as comparing the field with each value and joining the tests with | |
tcp.port in {443, 4430..4434} | Membership with a rangeTwo dots give a range; unlike a >= and <= pair, a single field must fall inside it. |
all tcp.port > 1024 | Require every field to matchThe all modifier makes each occurrence of the field satisfy the comparison. |
any ip.addr != 1.1.1.1 | Require any field to matchWith the any modifier, one occurrence passing the comparison is enough. |
tcp.flags & 0x02 | Bitwise ANDMatches packets whose TCP flags have the SYN bit set; bitand is the word form. |
Display filter slices and functions 9
| Shortcut | What it does |
|---|---|
http.content_type[0:4] == "text" | Slice from an offset[n:m] takes m units starting at offset n, here the first four characters of the field. |
frame[100-199] contains "wireshark" | Slice by offset range[n-m] gives start and end offsets; frame stands for all captured bytes of the packet. |
udp contains 81:60:03 | Search for a byte sequenceFinds the three bytes anywhere in the UDP header or payload. |
lower(http.server) contains "apache" | Case-insensitive comparisonlower() and upper() convert a string field before it is compared. |
len(http.request.uri) > 100 | Test the length of a fieldlen() counts bytes, not multi-byte characters. |
string(frame.number) matches "[13579]$" | Convert a field to a stringstring() turns a number or address into text so matches and contains work; this one finds odd frame numbers. |
max(tcp.srcport, tcp.dstport) <= 1024 | Compare the larger of two fieldsmax() and min() accept any number of arguments of one type. |
vals(pfcp.msg_type) contains "Request" | Test a field by its value stringvals() gives the text label of an integer or Boolean field, as custom columns show it. |
frame.time_relative >= ${frame.time_relative} - 300 | Field reference${field} is read from the packet selected in the GUI; this keeps the five minutes before it. |
Display filters by protocol 21
| Shortcut | What it does |
|---|---|
tcp | Show only TCP packetsAny protocol name works alone as a filter; names are usually lowercase. |
tcp.port == 443 | Match a TCP portMatches the source or the destination port; the membership operator tests several ports at once. |
tcp.port == 80 and ip.src == 192.168.2.1 | Match port and source addressEach field must exist and match, so only TCP packets from that address on port 80 remain. |
tcp.flags.syn == 1 | Show TCP SYN packetsA Boolean field exists whether the flag is 0 or 1, so compare it with 1 or True. |
ip.src==192.168.0.1 and tcp.flags.syn==1 | Find a host's connection attemptsThe guide gives it as a Find Packet search for the three-way handshake of a connection from that host. |
tcp.completeness==31 or tcp.completeness==47 or tcp.completeness==63 | Complete TCP conversations with dataThree values are needed because a connection may close with FIN, with RST or with both. |
tcp.payload contains "GET" | Search TCP payload for textThe quoted text is compared as UTF-8 bytes, so the byte form 47.45.54 gives the same result. |
ip.addr == 192.168.0.1 | Packets to or from an IP addressip.addr covers both directions; ip.src and ip.dst test only the source or the destination. |
ip.src == 192.168.1.1 | Match a source IP addressA hostname may be written in place of the dotted address. |
ip.addr == 129.111.0.0/16 | Match an IPv4 subnetCIDR notation: the number after the slash is the count of network bits. |
ip.addr in {10.0.0.5 .. 10.0.0.9, 192.168.1.1..192.168.1.9} | Match IP address rangesTwo dots join the ends of a range, and one set may hold several ranges. |
not ip.dst eq 224.1.2.3 | Exclude a destination addressAlso keeps non-IP packets, which a plain ne comparison on ip.dst would hide. |
ipv6.addr == ::1 | Match an IPv6 addressIPv6 addresses can also be tested against a subnet. |
eth.dst == ff:ff:ff:ff:ff:ff | Match an Ethernet addressThe six bytes may be separated by colons, dashes or dots, as in ffff.ffff.ffff. |
http.request | Show HTTP requestsNaming a field without a value keeps every packet in which that field is present. |
http.request.method == "POST" | Match an HTTP methodString values are written inside double quotes. |
http.request.method in {"HEAD", "GET"} | Match several HTTP methodsMembership sets take strings as well as numbers. |
http.request.uri == "https://www.wireshark.org/" | Match an exact request URIC-style escape sequences are accepted inside the quoted string. |
http contains "https://www.wireshark.org" | Search HTTP for a URLcontains cannot be applied to atomic fields such as numbers or IP addresses. |
http && ip.dst eq ${dns.a} | HTTP to a DNS answer addressSelect the DNS response first: ${dns.a} is filled in from the selected packet. |
frame.time < "2022-01-01" | Packets before a dateThe time may be left off but the whole date is required; values are read in the local time zone. |
Capture filters 17
Capture filters are written in the libpcap filter language, not in display filter syntax. They go in the Filter field of the Capture Options dialog or after -f; capitals here are placeholders.
| Shortcut | What it does |
|---|---|
tcp port 23 and host 10.0.0.5 | Telnet traffic of one hostTwo primitives joined by and: TCP port 23, and the host as source or destination. |
tcp port 23 and not src host 10.0.0.5 | Telnet except from one hostnot negates the primitive after it, here the source-host test. |
host HOST | Traffic to or from a hostTakes an IP address or a name and matches it as source or destination. |
src host HOST | Traffic sent by a hostThe src keyword limits the test to the source address. |
dst host HOST | Traffic sent to a hostThe dst keyword limits the test to the destination address. |
ether host EHOST | Match an Ethernet host addresssrc or dst may be placed between ether and host to test one direction only. |
gateway host HOST | Packets routed through a gatewayMatches the host as Ethernet source or destination when it is neither IP endpoint. |
net NET | Traffic of a networkMatches the network number as source or destination; put src or dst in front for one side. |
net NET mask MASK | Network with a netmaskNeeded when the netmask of that network differs from your own. |
port PORT | TCP or UDP portWithout tcp or udp in front, both protocols and both directions are matched. |
tcp port PORT | TCP port onlyThe protocol keyword has to come before src or dst. |
udp dst port PORT | UDP destination portCombines the protocol keyword with dst to test one port field of UDP packets. |
less LENGTH | Packets up to a lengthSelects packets whose length is at most the number given. |
greater LENGTH | Packets from a length upSelects packets at least as long as the number given. |
ip proto PROTOCOL | Protocol at the IP layerUse ether proto for a protocol at the Ethernet layer instead. |
ether broadcast | Ethernet broadcastsReplace ether with ip to select IP broadcasts instead. |
ether multicast | Ethernet multicastsThe ip keyword in place of ether selects IP multicast packets. |
Capture options on the command line 30
| Shortcut | What it does |
|---|---|
-D | List capture interfacesLong form --list-interfaces; prints a number and a name for each interface, then exits. |
-i INTERFACE | Choose the capture interfaceTakes a name or number from the -D list; long form --interface, repeatable to capture on several interfaces. |
-i - | Capture from standard inputThe dash stands for stdin; a FIFO name works the same way and the data must be pcap or pcapng. |
-k | Start capturing immediatelyWithout -i, Wireshark picks the first non-loopback interface, or the first loopback one if no other exists. |
-f FILTER | Set the capture filterBefore the first -i it is the default for every interface; after an -i it applies to that interface only. |
-f "predef:MyPredefinedHostOnlyFilter" | Use a saved capture filterThe predef: prefix refers to a filter name listed under Capture > Capture Filters. |
-w OUTFILE | Name the capture fileA single dash as the name sends the capture to standard output. |
-F FORMAT | Set the output file formatFor a -k capture written with -w; pcapng is the default, and -F with no value lists the formats. |
-a duration:NUM | Stop capturing after a timeNUM is in seconds and may be a fraction such as 0.5; --autostop is the long form. |
-a filesize:NUM | Stop at a file sizeNUM is in kB; combined with -b, Wireshark moves on to the next file instead. |
-a files:NUM | Stop after a number of filesCounts the capture files written in multiple-files mode. |
-a packets:NUM | Stop after a packet countHas the same effect as the -c option. |
-c COUNT | Limit the packets capturedCaps a live capture at that many packets, like the packets: condition of -a. |
-b filesize:1000 -b files:5 | Ring buffer of five 1 MB filesEach -b takes one criterion; files: makes Wireshark overwrite the oldest file once that count is reached. |
-b duration:NUM | Switch files by timeOpens the next capture file after NUM seconds even when the current one is not full. |
-b packets:NUM | Switch files by packet countMoves to a new file once the current one holds NUM packets. |
-b interval:NUM | Switch files on the clockStarts a new file each time the clock reaches a whole multiple of NUM seconds. |
-B SIZE | Set the capture buffer sizeIn MiB, 2 by default; raise it when packets are dropped during capture. Long form --buffer-size. |
-s SNAPLEN | Set the snapshot lengthKeeps at most that many bytes of each packet; 0, the default, means 262144 so whole packets are stored. |
-p | Do not use promiscuous modeLong form --no-promiscuous-mode; the interface may still be promiscuous for some other reason. |
-I | Capture in monitor modeLong form --monitor-mode; only for 802.11 Wi-Fi interfaces on some systems, and the adapter may leave its network. |
-y LINKTYPE | Choose the link-layer typeApplies to a capture started with -k; use one of the values that -L reports. |
-L | List data link typesLong form --list-data-link-types; prints what the interface supports and exits. |
--list-time-stamp-types | List time stamp typesPrints nothing when the time stamp type of the interface cannot be set. |
--time-stamp-type TYPE | Set the time stamp methodChoose a type from the output of --list-time-stamp-types. |
--capture-comment COMMENT | Add a capture commentWorks with -k when the file format supports comments; only the first one is displayed. |
-S | Update the packet list liveAdds new packets to the list while the capture is still running. |
-l | Scroll with new packetsOnly has an effect while the list is updated live, which -S turns on. |
-H | Suppress capture info dialog |
--update-interval INTERVAL | Set the packet report intervalMilliseconds between packet reports, 100 by default; duration-based file switching uses the same step. |
File and display options 20
| Shortcut | What it does |
|---|---|
-r INFILE | Open a capture fileLong form --read-file; reads any supported format, compressed files included, but not pipes or stdin. |
-Y FILTER | Start with a display filterLong form --display-filter; the expression follows the display filter syntax. |
-R FILTER | Apply a read filterUsed with -r: packets that fail the display-filter expression are discarded while the file loads. |
-g NUMBER | Go to a packet numberAfter a file has been read with -r, selects the packet with that number. |
-J FILTER | Jump to a matching packetAfter -r, selects the first packet the display filter matches, or the next one when no exact match exists. |
-j | Jump backward on no matchPlaced after -J, it selects the nearest earlier packet when nothing matches exactly. |
-C PROFILE | Load a configuration profile |
-o PREFNAME:VALUE | Override a preferenceBeats the default and the value in the preference or recent file; the name is the one used in that file. |
-t a | Show absolute time of dayLocal time of capture without the date; add .N for N decimals, 0 through 9. |
-t ad | Show absolute date and timeThe date appears as YYYY-MM-DD in front of the local capture time. |
-t r | Show time since first packetRelative time is the default format of the time column. |
-u hms | Show seconds as h:m:sAffects the relative and delta formats chosen with -t; plain seconds, s, is the default. |
--fullscreen | Start in full screenKiosk mode; leave it from the View menu or with the full-screen key. |
--display DISPLAY | Choose the X displayAccepts a host and screen or just a screen such as :0.0; not available on macOS or Windows. |
--temp-dir DIRECTORY | Set the temporary file directoryOtherwise $TMPDIR or the system default is used on UNIX-like systems and %TEMP% on Windows. |
-P persconf:PATH | Set the personal configuration pathFor special cases such as running Wireshark from a USB stick. |
-P persdata:PATH | Set the personal data pathSecond key of the same option, for personal data files. |
-X lua_script:my.lua | Load a Lua scriptLoaded in addition to the default Lua scripts; -X lua_script1:foo then passes foo to it. |
-h | Show help and exitLong form --help; prints the version number followed by the option list. |
-v | Show version and exitLong form --version; prints the full version information. |
Dissection and name resolution options 10
| Shortcut | What it does |
|---|---|
-d tcp.port==8888,http | Decode a port as a protocolCommand-line form of Decode As: traffic on TCP port 8888 is dissected as HTTP. |
-n | Disable name resolutionTurns off host and port name lookups; a later -N can override it. |
-N FLAGS | Resolve selected name typesLetters pick what is resolved, such as m for MAC, n for network and t for port names; the default is dmN. |
--disable-protocol PROTO_NAME | Disable a protocol dissectorTakes a comma-separated list; ALL switches every protocol off for the session, whatever the profile says. |
--enable-protocol PROTO_NAME | Enable a protocol dissectorALL turns on every protocol that is enabled by default, overriding the disabled list of the profile. |
--disable-all-protocols | Disable all dissectors |
--only-protocols PROTOCOLS | Dissect only listed protocolsGive the protocol names separated by commas; every other dissector is switched off. |
--disable-heuristic SHORT_NAME | Disable a heuristic dissector |
--enable-heuristic SHORT_NAME | Enable a heuristic dissector |
-K krb5.keytab | Load Kerberos keysReads crypto keys from a keytab file; repeat the option to load several files. |
Statistics windows at startup 23
| Shortcut | What it does |
|---|---|
-z STATISTICS | Open a statistics windowThe window updates while packets arrive; the option can be given several times. |
-z help | List the statistics namesPrints every value that -z accepts. |
-z io,stat | I/O graph windowOpens up to five colour-coded graphs of packets or bytes per second, in one-second intervals. |
-z conv,TYPE | Conversation tableTYPE is an endpoint type such as eth, ip, ipv6, tcp or udp; an optional filter may follow. |
-z expert | Expert informationExpert items flag notable or unusual behaviour, such as bad checksums or retransmissions. |
-z voip,calls | VoIP calls windowOpens the window that the VoIP Calls menu command shows. |
-z dhcp,stat | DHCP statisticsCovers DHCP and BOOTP messages; a filter can be appended after a comma. |
-z sip,stat | SIP message counterCounts each SIP method and status code, and the resent messages. |
-z smb,srt | SMB service response timesReports the number of calls with minimum, maximum and average response time per SMB command. |
-z "smb,srt,ip.addr==1.2.3.4" | Limit a statistic with a filterAdd a display filter as the last field and quote the whole argument; here only one host is counted. |
-z rpc,programs | ONC-RPC program response timesLists calls and response times for every known program and version. |
-z ldap,srt | LDAP service response timesCalls and response times are grouped by LDAP command. |
-z afp,srt | AFP service response timesAFP is the Apple Filing Protocol. |
-z fc,srt | Fibre Channel response timesCalls and response times are listed per Fibre Channel command. |
-z scsi,srt,0 | SCSI response timesThe last field is the command set: 0 for SBC, 1 for SSC, 5 for MMC. |
-z h225,counter | H.225 message counterCounts H.225 messages and the reasons given in them. |
-z h225,srt | H.225 RAS response timesStatistics are kept per RAS message type. |
-z megaco,srt | MEGACO response timesRequest and response timing per MEGACO command, laid out like the SMB table. |
-z mgcp,srt | MGCP response timesRequest and response timing per MGCP type. |
-z mtp3,msus | MTP3 MSU statistics |
-z multicast,stat | UDP multicast stream statistics |
-z wlan,stat | WLAN traffic statisticsCovers IEEE 802.11 networks and their stations. |
-z wsp,stat | WSP packet counters |
Logging options 7
| Shortcut | What it does |
|---|---|
--log-level LEVEL | Set the log levelLevels run from noisy and debug up to critical and error; the chosen level and those above it are printed. |
--log-fatal LEVEL | Abort at a log levelWith warning, for example, any warning, critical or error message ends the program. |
--log-domains LIST | Limit logging to domainsA comma-separated list such as GUI,Epan,sshdump; a leading ! inverts the match. |
--log-debug LIST | Log domains at debug levelForces the listed domains to debug whatever the active level is. |
--log-noisy LIST | Log domains at noisy levelNoisy is the most verbose level; the domains are separated by commas. |
--log-fatal-domains LIST | Abort on messages from domainsAny message logged for one of the listed domains stops the program. |
--log-file PATH | Write the log to a fileThe file receives the log messages together with stderr output. |
Capture and file shortcuts 15
The guide writes its shortcuts with Ctrl and names a macOS key for a few items only: Cmd + , for Preferences, Shift + Cmd + A for Configuration Profiles and Option with the arrow keys for the selection history.
| Shortcut | What it does |
|---|---|
| Ctrl+K | Capture optionsOpens the dialog where interfaces and their capture settings are configured. |
| Ctrl+E | Start captureBegins capturing at once, reusing the settings of the previous capture. |
| Ctrl+E | Stop captureThe same key ends the capture that is running. |
| Ctrl+R | Restart captureStops the running capture and begins a new one with identical options; packets captured so far are removed. |
| F5 | Refresh interfacesClears the interface list and builds it again. |
| Ctrl+O | Open capture fileShows the file dialog for loading a saved capture. |
| Ctrl+W | Close capture fileAsks to save an unsaved capture first, unless a preference turns the question off. |
| Ctrl+S | Save capture fileOpens Save Capture File As when no default file name has been set. |
| Ctrl+Shift+S | Save AsWrites the current capture to a file of your choice. |
| Ctrl+Shift+X | Export packet bytesSaves the raw bytes of the selected item to a binary file. |
| Ctrl+P | Print packetsOpens the Print dialog for all or part of the capture. |
| Ctrl+R | Reload capture fileReads the open file again; Restart in the Capture menu is documented with the same key. |
| Ctrl+Shift+F | Toggle file format viewSwitches between the normal frame list and the internal structure of the file, where the file type supports it. |
| Ctrl+Alt+Shift+C | Capture File PropertiesOpens the dialog with details about the loaded capture file. |
| Ctrl+Q | Quit WiresharkOffers to save an unsaved capture before exiting. |
Packet details and bytes 15
| Shortcut | What it does |
|---|---|
| Right | Expand tree itemOpens the item selected in the packet detail pane. |
| Left | Collapse tree itemIf the item is closed already, the selection jumps to its parent. |
| Shift+Right | Expand item and subtreesOpens the selected item together with everything beneath it. |
| Shift+Left | Collapse subtreesCloses the branch that is selected in the details pane. |
| Ctrl+Right | Expand allOpens every tree item; Wireshark keeps the expanded subtrees open for the packets you view next. |
| Ctrl+Left | Collapse allCloses every item of the detail tree. |
| Backspace | Go to parent nodeMoves the selection up one level in the detail tree. |
| EnterorReturn | Toggle tree itemOpens a closed item and closes an open one. |
| Ctrl+Shift+I | Apply as columnAdds the field selected in the details pane to the packet list as a new column. |
| Ctrl+Shift+C | Copy as filterPuts a display filter built from the selected item on the clipboard. |
| Ctrl+Alt+Shift+D | Copy descriptionCopies the text of the selected field as the tree shows it. |
| Ctrl+Alt+Shift+F | Copy field nameCopies the name of the selected field rather than its content. |
| Ctrl+Alt+Shift+V | Copy valueCopies only the content of the selected field. |
| Ctrl+Alt+Shift+A | Copy all visible itemsCopies the packet details as they are currently displayed. |
| Ctrl | Freeze hover highlightHold it while moving the mouse over the packet bytes pane to keep the highlighted field. |
Finding, marking and ignoring packets 14
| Shortcut | What it does |
|---|---|
| Ctrl+/ | Focus the display filterPuts the cursor in the display filter box of the main window. |
| Ctrl+F | Find packetOpens a toolbar that searches by display filter, hex value, string or regular expression. |
| Ctrl+N | Find nextRepeats the search forward with the current Find Packet settings. |
| Ctrl+B | Find previousSearches backward with the current Find Packet settings. |
| Ctrl+M | Mark or unmark packetMarked packets get a black background and can be chosen as a range when saving, exporting or printing. |
| Middle-click | Mark packet with the mouseClick a row of the packet list to toggle its mark. |
| Ctrl+Shift+M | Mark all displayed packetsMarks are not stored in the capture file and are lost when it is closed. |
| Ctrl+Alt+M | Unmark all displayed packets |
| Ctrl+Shift+N | Next markJumps forward to the nearest marked packet. |
| Ctrl+Shift+B | Previous markJumps back to the nearest marked packet. |
| Ctrl+D | Ignore or unignore packetWireshark then treats the packet as if it were not in the file and shows it grey on white. |
| Ctrl+Shift+D | Ignore all displayed packetsThe ignored state is kept only until the capture file is closed. |
| Ctrl+Alt+D | Unignore all displayed packets |
| Ctrl+Alt+C | Packet commentAdds a comment to one packet; pcapng files can store comments, pcap files cannot. |
Time references and time display 13
| Shortcut | What it does |
|---|---|
| Ctrl+T | Set or unset time referenceLater packets show the time elapsed since the referenced packet, which is labelled *REF*. |
| Ctrl+Alt+T | Unset all time referencesTime references are not saved and disappear when the file is closed. |
| Ctrl+Alt+N | Next time referenceJumps forward to the nearest time-referenced packet. |
| Ctrl+Alt+B | Previous time referenceJumps back to the nearest time-referenced packet. |
| Ctrl+Shift+T | Time shiftOpens a dialog that moves the timestamps of chosen packets or of the whole capture. |
| Ctrl+Alt+1 | Absolute date and time formatShows each packet's local capture date together with the clock time. |
| Ctrl+Alt+2 | Time-of-day formatShows the local clock time without the date. |
| Ctrl+Alt+3 | Epoch seconds formatCounts seconds from 1 January 1970, the UNIX epoch. |
| Ctrl+Alt+4 | Seconds since first packetRelative time from the first captured packet, or from the latest time reference. |
| Ctrl+Alt+5 | Delta from previous captured packetShows the gap to the packet captured just before, whether or not it is displayed. |
| Ctrl+Alt+6 | Delta from previous displayed packetMeasures from the previous packet that passes the display filter. |
| Ctrl+Alt+7 | UTC date and time formatLike the first format, but in UTC instead of local time. |
| Ctrl+Alt+8 | UTC time-of-day formatClock time in UTC, without the date. |
Following streams and analysis 9
| Shortcut | What it does |
|---|---|
| Ctrl+Alt+Shift+T | Follow TCP streamApplies a display filter for the selected packet's stream and shows its data in a dialog. |
| Ctrl+Alt+Shift+U | Follow UDP streamThe Follow entry is disabled unless the selected packet contains UDP. |
| Ctrl+Alt+Shift+S | Follow TLS streamTLS keys have to be supplied before the decrypted stream can be read. |
| Ctrl+Alt+Shift+H | Follow HTTP streamThe dialog is very similar to the one for TCP streams. |
| Ctrl+Alt+Shift+E | Follow DCCP stream |
| Ctrl+Shift+U | Decode AsOpens the dialog for decoding certain packets as a protocol you choose. |
| Ctrl+Shift+E | Enabled ProtocolsOpens the dialog where individual protocol dissectors are switched on or off. |
| Ctrl+Shift+O | Show Packet BytesOpens a window that can decode, decompress or reinterpret the selected bytes. |
| Ctrl+Shift+L | Reload Lua plugins |
View, zoom and coloring 11
| Shortcut | What it does |
|---|---|
| Ctrl++orCtrl+= | Zoom inEnlarges the font used for the packet data. |
| Ctrl+- | Zoom outMakes the packet data font smaller. |
| Ctrl+0 | Normal sizeReturns the zoom level to 100%. |
| Ctrl+Shift+R | Resize all columnsFits every column to its content, which can be slow with a large capture file. |
| Ctrl+Shift+W | Reset layoutReturns the panes of the main window to their default sizes. |
| F11orCtrl+Cmd+F | Toggle full screenCtrl + Cmd + F is the macOS key; the View menu has a Full Screen item as well. |
| Ctrl+1 | Colorize conversationGives the conversation of the selected packet temporary color 1; Ctrl with 2 to 9 applies the other colors. |
| Ctrl+Space | Reset colorizationRemoves every temporary conversation color at once. |
| Ctrl+Shift+PorCmd+, | PreferencesOpens the Preferences dialog; Cmd + , is the binding the guide gives for macOS. |
| Ctrl+Shift+AorCmd+Shift+A | Configuration ProfilesProfiles hold separate sets of preferences and configurations; the Cmd form is for macOS. |
| F1 | Open the User's GuideTries the locally installed guide first and falls back to the online copy. |
No row on this page matches that filter.
Notes
Display filters that solve most investigations
ip.addr == 192.168.0.1 matches packets to or from a host — use ip.src or ip.dst when direction matters. tcp.port == 443 isolates a service, and a protocol name alone, such as tcp, selects every packet that contains that protocol; http.request narrows HTTP to its requests. tcp.flags.syn == 1 shows connection attempts, which is the fastest way to see whether a client is even reaching a server; the guide's own example adds the client address, ip.src==192.168.0.1 and tcp.flags.syn==1. frame.len > 10 is the pattern for size tests, and not llc the pattern for hiding a protocol. Display filters are not capture filters: they hide packets already captured, and the syntax differs from the libpcap language used by -f FILTER.
Starting captures from the command line
All options follow the wireshark command name. -D prints the interfaces Wireshark can see, and -i INTERFACE picks one — -i - reads from standard input instead. -k starts capturing immediately instead of waiting for a click, and -f FILTER applies a capture filter so only matching packets are written. For long-running captures, -b filesize:1000 -b files:5 keeps a ring of five one-megabyte files and -a duration:NUM stops after a set time (size, file-count and packet limits exist too), which prevents a forgotten capture from filling a disk.
Reading files back
-r INFILE opens a capture; add -g NUMBER to land on a packet number or -J FILTER to jump to the first packet matching a display filter — with -j choosing the packet before when nothing matches exactly. -C PROFILE starts with a named configuration profile, useful when you keep separate colouring rules for different networks. For anything non-interactive, the companion tshark program uses the same display filter engine.
Keys worth learning in the main window
Ctrl + E starts a capture and stops it again; Ctrl + K opens the capture options first. Ctrl + Down and Ctrl + Up (or F8 and F7) step through packets from any pane, Ctrl + G jumps to a packet number and Ctrl + F opens the Find Packet toolbar. Ctrl + M marks a packet so that Ctrl + Shift + N can return to it, and Ctrl + Alt + Shift + T follows the TCP stream of the selected packet. Typing anywhere in the main window starts a display filter.
Questions
What is the difference between a display filter and a capture filter?
Display filters (typed in the filter toolbar) hide packets already captured and use Wireshark's own syntax. Capture filters (the Capture Options dialog, or -f on the command line) decide what is recorded and use the libpcap filter language, the one described in pcap-filter(7) and used by tcpdump.
How do I see only the connection attempts of one host?
Filter on the source address and the SYN flag: ip.src==192.168.0.1 and tcp.flags.syn==1 is the guide's example for finding the three-way handshake of a connection from that host. tcp.flags.syn == 1 alone shows every packet with SYN set.
How do I stop a capture from filling the disk?
Use -b for a ring buffer of rotating files, for example -b filesize:1000 -b files:5, or -a with a duration, filesize, files or packets limit.
Why is Ctrl+R listed for both Restart and Reload?
The guide gives Ctrl+R to Capture > Restart and to View > Reload. Restart stops a running capture and starts it again with the same options; Reload reads the open capture file again.
Which key follows a TCP stream in Wireshark?
Ctrl + Alt + Shift + T in Wireshark 4.6.9. UDP, TLS and HTTP streams use the same three modifiers with U, S and H, and the menu entry is Analyze > Follow.
Do these filters and options work in tshark?
The display filter syntax does: the man page says Wireshark and TShark share one filter engine, and tshark takes -Y for a display filter. The other tshark options are documented in tshark(1) and are not listed here.
Sources and checks
- wireshark(1) manual page — wireshark.org (online edition) Command-line options, the -z statistics list and the F1 and full-screen keys
- wireshark-filter(4) manual page — wireshark.org (online edition) Display filter syntax: operators, slices, functions and the example filters
- Wireshark User’s Guide, version 4.7.4 — wireshark.org (single-page edition) Display filter operator tables, capture filter primitives, keyboard navigation and menu shortcut tables, wireshark -h output
- Wireshark 4.6.9 source, ui/qt/wireshark_main_window.ui (tag v4.6.9, official GitHub mirror) Default main-window shortcuts of the stable release that the guide's menu tables leave out
- Wireshark 4.6.9 source, ui/qt/wireshark_main_window.cpp (tag v4.6.9, official GitHub mirror) Follow-stream shortcuts and the display-filter focus key, which are set in code
Every row on this page was matched to a line in the documentation above on . A binding that could not be found there is not listed.
3 rows from the earlier version of this page were removed in that check: duplicates, and bindings the documentation does not list or lists differently.
Found a wrong or missing key? Tell us and it gets checked against the source. How we verify describes the process and its limits.