Frame and packet headers at a glance

One table per header, from the wire up. Sizes are in bits unless they say bytes. Keep this open beside a Wireshark capture and match each field to what you see.

Ethernet II

FieldSizePurpose
Preamble and SFD7 + 1 bytesAlternating 1s and 0s to synchronise, then 10101011 to mark the start. Sent by the physical layer, not counted in the frame size
Destination MAC6 bytesUnicast, multicast (01-00-5E… for IPv4, 33-33… for IPv6) or broadcast FF-FF-FF-FF-FF-FF
Source MAC6 bytesAlways unicast; what the switch learns
EtherType2 bytesThe payload's protocol: 0x0800 IPv4, 0x86DD IPv6, 0x0806 ARP. A value of 1500 or less is a length instead (802.3 with LLC)
Payload46–1500 bytesPadded up to 46 bytes when shorter
FCS4 bytesA CRC-32 over the frame; a frame that fails it is dropped and counted as a CRC error

A frame is 64 to 1518 bytes, or up to 1522 with an 802.1Q tag. Anything shorter is a runt, anything longer a giant (unless jumbo frames are on).

The 802.1Q tag

FieldSizePurpose
TPID160x8100: says a tag follows; sits where the EtherType was
PCP3Priority 0–7 for QoS (802.1p); voice usually 5
DEI1Drop eligible: may be dropped first under congestion
VID12The VLAN, 1–4094 (0 and 4095 are reserved)

IPv4

FieldSizePurpose
Version44
IHL4Header length in 32-bit words: 5 (20 bytes) without options, up to 15 (60 bytes)
DSCP and ECN6 + 2QoS marking, and congestion notification
Total length16Header and data in bytes, up to 65,535
Identification16Ties the fragments of one packet together
Flags3Reserved, Don't Fragment (DF), More Fragments (MF)
Fragment offset13Where this fragment sits, in 8-byte units
TTL8Each router subtracts 1 and drops the packet at 0, sending ICMP Time Exceeded (what traceroute uses)
Protocol8What the data is: 1 ICMP, 6 TCP, 17 UDP, 89 OSPF…
Header checksum16Checks the header only; recomputed by each router because the TTL changes
Source and destination32 + 32The addresses

IPv6

FieldSizePurpose
Version46
Traffic class8DSCP and ECN, as in IPv4
Flow label20Marks packets of one flow so routers can keep them on one path
Payload length16Bytes after this 40-byte header, extension headers included
Next header8The next header's type: 6 TCP, 17 UDP, 58 ICMPv6, or an extension header
Hop limit8IPv4's TTL under its real name
Source and destination128 + 128The addresses

The IPv6 header is a fixed 40 bytes with no checksum and no fragmentation fields: routers never fragment, only the sender does (with an extension header), after Path MTU Discovery.

TCP and UDP

TCP fieldSizePurpose
Source and destination port16 + 16Which application on each host
Sequence number32Number of the first byte in this segment
Acknowledgment number32The next byte expected from the other side
Data offset4Header length in 32-bit words: 20 to 60 bytes
Reserved4Zero
Flags8CWR, ECE, URG, ACK, PSH, RST, SYN, FIN (older books show only the last six)
Window16How many bytes the receiver can take now: flow control
Checksum16Over the header, the data and a pseudo-header of the IP addresses
Urgent pointer16Used with URG; rare today
UDP fieldSizePurpose
Source and destination port16 + 16Which application
Length16Header and data in bytes
Checksum16Optional over IPv4, required over IPv6

TCP opens a connection with a three-way handshake (SYN, SYN-ACK, ACK), numbers every byte, acknowledges what arrived, resends what did not and slows down when the receiver's window closes. UDP's header is 8 bytes and does none of that, which suits DNS, voice and video, where late is as bad as lost.

HDLC and PPP on serial links

Not on the current CCNA, but still found on older WAN links. Both frames start and end with the flag 01111110 (0x7E). On synchronous links the sender inserts a 0 after any five 1s in the data (bit stuffing), so the flag never appears inside a frame.

FieldHDLCPPP
Flag0x7E0x7E
AddressThe station; 8 bits or moreAlways 0xFF (all stations): a point-to-point link needs none
ControlFrame type (information, supervisory, unnumbered) with sequence numbersAlways 0x03 (unnumbered information)
ProtocolNone in ISO HDLC; Cisco's HDLC adds a 2-byte type, which is why it only talks to Cisco2 bytes: 0x0021 IPv4, 0x0057 IPv6, 0xC021 LCP, 0x8021 IPCP, 0xC023 PAP, 0xC223 CHAP
DataVariableVariable, 1500 bytes by default (the MRU)
FCSCRC-16 or CRC-32CRC-16 or CRC-32

PPP may leave out the address and control bytes and shorten the protocol to one byte once both ends agree (ACFC and PFC, negotiated by LCP). Its value over Cisco HDLC is that it works between vendors and brings authentication (PAP, CHAP).