HTTP/1.1 (1997) dùng text-based protocol, mỗi request cần một TCP connection riêng hoặc dùng persistent connection nhưng bị head-of-line blocking (request sau phải chờ response trước).
HTTP/2 (2015) giới thiệu binary framing, multiplexing (nhiều request/response cùng lúc trên 1 TCP connection), header compression (HPACK), server push — giảm đáng kể latency cho web hiện đại.
HTTP/3 (2022) bỏ hẳn TCP, dùng QUIC protocol trên UDP: giải quyết TCP-level head-of-line blocking, 0-RTT connection resumption, built-in TLS 1.3. Thực tế: hầu hết browser và CDN đã support HTTP/2; HTTP/3 ngày càng phổ biến qua Cloudflare, Google. Lập trình viên thường không cần config trực tiếp — Nginx/reverse proxy xử lý — nhưng hiểu nguyên lý giúp tối ưu asset bundling và caching strategy.
HTTP/1.1 (1997) uses a text-based protocol; each request either requires its own TCP connection or shares a persistent connection that suffers from head-of-line blocking (each response must complete before the next request can proceed).
HTTP/2 (2015) introduced binary framing, multiplexing (multiple request/response pairs concurrently over a single TCP connection), header compression (HPACK), and server push — dramatically reducing latency for modern web apps.
HTTP/3 (2022) drops TCP entirely, using QUIC over UDP: it eliminates TCP-level head-of-line blocking, supports 0-RTT connection resumption, and has TLS 1.3 built in. In practice, most browsers and CDNs already support HTTP/2; HTTP/3 is increasingly common via Cloudflare and Google. Developers rarely configure this directly — Nginx or a reverse proxy handles it — but understanding the principles helps optimize asset bundling and caching strategies.