HTTP/3 and QUIC: Why They Matter for the Web
You might noticed "h3" in your browser dev tools protocol column. That's HTTP/3, and it's the biggest change to the web since HTTP/1.1.
The Problem with HTTP/2 (and TCP)
HTTP/2 introduced multiplexing—sending multiple files over one TCP connection. This was great, but it had a flaw called Head-of-Line Blocking.
If one packet gets lost in TCP (e.g., bad WiFi), all streams on that connection must wait until it is retransmitted. So one lost image packet delays your CSS and JS too.
Enter QUIC (built on UDP)
HTTP/3 abandons TCP for UDP.
"But wait, isn't UDP unreliable?" Yes, but QUIC implements reliability on top of UDP, in user space.
Key Benefits
- No Head-of-Line Blocking: Streams are independent. Packet loss in stream A doesn't affect stream B.
- Faster Handshakes: TLS 1.3 is built-in. Connects in 0 or 1 round trip (vs 2-3 for separate TCP+TLS).
- Connection Migration: Switch from WiFi to 5G without breaking connections. (No more "Network Changed" errors).
Comparison
| Feature | HTTP/1.1 | HTTP/2 | HTTP/3 |
|---|---|---|---|
| Transport | TCP | TCP | UDP (QUIC) |
| Multiplexing | No | Yes | Yes |
| HOL Blocking | Problem | Problem (TCP level) | Solved |
| Security | Optional | Effectively Mandatory | Mandatory |
How to Use It
Server Side
Nginx added support in version 1.25.
server {
listen 443 quic reuseport;
listen 443 ssl;
# Advertise HTTP/3 support
add_header Alt-Svc 'h3=":443"; ma=86400';
}
Cloudflare and AWS CloudFront support it out of the box.
Client Side
All modern browsers (Chrome, Firefox, Safari) support it. You don't need to change your JS code.
fetch('https://example.com') works exactly the same.
Should You Care?
If you build:
- Video streaming apps
- Real-time collaboration tools
- Apps for users with poor connectivity (e.g., rural India 4G)
Then HTTP/3 is a massive upgrade. It makes the web feel faster and more resilient. The future is UDP.