HTTP1.1 vs HTTP2:What’s the difference?

Roshni Kushwaha
3 min readNov 6, 2020

Introduction

The Hypertext Transfer Protocol(HTTP), is an application protocol that has been the de facto standard for communication on the World Wide Web since its invention in 1989. From the release of HTTP1.1 in 1997 until recently, there have been few revisions to the protocol. But in 2015, a reimagined version called HTTP2 came into use, which offered several methods to decrease latency, especially when dealing with mobile platforms and server-intensive graphics and videos. HTTP2 has since become increasingly popular, with some estimates suggesting that around a third of all websites in the world support it. In this changing landscape, web developers can benefit from understanding the technical differences between HTTP1.1 and HTTP2, allowing them to make informed and efficient decisions about evolving best practices.

HTTP1.1

Developed by Timothy Berners-Lee in 1989 as a communication standard for the World Wide Web, HTTP is a top-level application protocol that exchanges information between a client computer and a local or remote web server. In this process, a client sends a text-based request to a server by calling a method like GET or POST. In response, the server sends a resource like an HTML page back to the client.

For example, let’s say you are visiting a website at the domain www.example.com. When you navigate to this URL, the web browser on your computer sends an HTTP request in the form of a text-based message, similar to the one shown here:

This request uses the GET method, which asks for data from the host server listed after Host:. In response to this request, the example.com web server returns an HTML page to the requesting client, in addition to any images, stylesheets, or other resources called for in the HTML. Note that not all of the resources are returned to the client in the first call for data. The requests and responses will go back and forth between the server and client until the web browser has received all the resources necessary to render the contents of the HTML page on your screen.

You can think of this exchange of requests and responses as a single application layer of the internet protocol stack, sitting on top of the transfer layer (usually using the Transmission Control Protocol, or TCP) and networking layers (using the Internet Protocol, or IP):

There is much to discuss about the lower levels of this stack, but in order to gain a high-level understanding of HTTP2, you only need to know this abstracted layer model and where HTTP figures into it.

HTTP2

HTTP/2 is a major revision of the HTTP network protocol used by the World Wide Web. It was derived from the earlier experimental SPDY protocol, originally developed by Google. HTTP2 was developed by the HTTP Working Group of the Internet Engineering Task Force.

From a technical point of view, one of the most significant features that distinguishes HTTP1.1 and HTTP2 is the binary framing layer, which can be thought of as a part of the application layer in the internet protocol stack. As opposed to HTTP1.1, which keeps all requests and responses in plain text format.

These are the high-level differences between HTTP1 and HTTP2: HTTP2 is binary, instead of textual. HTTP2 is fully multiplexed, instead of ordered and blocking. … HTTP2 allows servers to “push” responses proactively into client caches.

--

--