What will happen when you open an URL in a browser?
🇺🇸
Through DNS, client (the browser) will resolve hostname of the URL to an IP address of the destination server. Then it establishes a TCP connection through a three-way handshake. On top of TCP connection, it establishes TLS connection though TLS handshake, so that only encrypted data is sent over the network. The client uses HTTP Protocol to send a request which contains headers and request payload to the destination server. The server responds with a status code, headers and response payload.
HTTP/2 allows multiple HTTP requests and responses to be sent and received simultaneously over a single TCP connection; in HTTP/1.1, each request and response is sent and received over a single TCP connection. This allows HTTP/2 to provide potentially significant performance gains in networks with limited bandwidth.
The difference is that HTTP/2 uses a binary framing layer, whereas HTTP/1.1 keeps all requests and responses in plain text format.
HTTP/2 improves the efficiency of HTTP by converting and encapsulating messages into binary format
HTTP/2 also differs in that it allows servers to push data to clients using PUSH frames.