Sending Before Asking
HTTP2 introduced server push, letting a server send resources the client has not requested yet. The idea was to deliver the stylesheet and scripts alongside the HTML page, saving a round trip.
How Push Worked
- The server sends a PUSH PROMISE frame describing a response it intends to push.
- It then streams that response on a new stream over the same connection.
- The client can store pushed responses in a special push cache for when it discovers the matching request.
Why It Disappointed
Push often wasted bandwidth by sending resources the client already had cached. Coordinating the cache was hard, and the gains over a hint based approach were small. Major browsers removed support, and the ecosystem moved to the Link rel preload header and 103 Early Hints, which suggest resources without forcing them.
Key idea
HTTP2 server push proactively delivered resources but often wasted bandwidth, so the web shifted to preload hints and Early Hints instead.