Understanding MTU, MSS, and Tunnel Overhead
What is the Difference Between MTU and MSS?
MTU (Maximum Transmission Unit) is a Layer 3 concept — the largest IP packet that can traverse a network link without fragmentation. Standard Ethernet MTU is 1500 bytes, but PPPoE links use 1492, and jumbo frames support up to 9000 bytes. MSS (Maximum Segment Size) is a Layer 4 TCP concept — the maximum TCP payload (data) in a single segment. MSS is negotiated during the TCP three-way handshake and is typically calculated as MSS = MTU - IP Header - TCP Header.
When tunnel encapsulation is involved, additional headers (GRE, IPsec, VXLAN, WireGuard) reduce the available space for TCP data. The MSS must be clamped to a lower value to prevent IP fragmentation. Use this MTU MSS overhead calculator to determine the exact MSS for any combination of tunnel protocols.
Why Do VPNs Cause Web Pages to Load Slowly?
VPNs and tunnels add encapsulation headers that increase packet size beyond the physical interface MTU. For example, a 1500-byte TCP packet going through an IPsec tunnel with 50 bytes of overhead becomes 1550 bytes — too large for the Ethernet link. The router either fragments the packet (which hurts performance and is often blocked by firewalls) or sends an ICMP "Fragmentation Needed" message back to the sender. However, many firewalls and middleboxes silently drop ICMP messages (a phenomenon called ICMP black hole or PMTUD failure), causing the sender to never learn about the smaller MTU. The result: TCP retransmits endlessly, web pages hang, and connections time out.
TCP MSS clamping solves this by rewriting the MSS value in TCP SYN packets so that the sender never generates segments larger than the tunnel can carry. This calculator helps you determine the correct MSS clamp value for your specific tunnel stack.
Reference Table: Protocol Overhead by Byte
| Protocol / Header | Overhead (Bytes) | Notes |
|---|---|---|
| Ethernet (Standard) | 14 | MAC dst + src + EtherType |
| Ethernet + 802.1Q VLAN | 18 | Adds 4-byte VLAN tag |
| Ethernet + QinQ | 22 | Double VLAN tagging |
| PPPoE | 8 | PPPoE session + PPP protocol |
| GRE (IPv4) | 24 | Standard GRE with key/seq |
| IPsec ESP (Tunnel) | ~50 | AES-GCM-128 + HMAC-SHA256 average |
| VXLAN | 50 | Outer Eth 14 + IP 20 + UDP 8 + VXLAN 8 |
| WireGuard | 40 | Outer IP 20 + UDP 8 + WG 12 |
| OpenVPN | ~68 | UDP mode + TLS + HMAC (typical) |
| L2TP / IPsec | ~80 | L2TP + UDP + IPsec ESP |
| Geneve / NVGRE | 58 | Outer Eth 14 + IP 20 + UDP 8 + Geneve 16 |
| IPv4 | 20 | Standard IPv4 header (no options) |
| IPv6 | 40 | Standard IPv6 header (no extensions) |
| TCP | 20 | Standard TCP header (no options) |
| UDP | 8 | Standard UDP header |