Journey of HTTP

HTTP 0.9→HTTP 1.0→HTTP 1.1→HTTP 2.0→HTTP 3.0

HTTP is a request-response protocol, which means that a client sends a request to a server, and the server returns a response. The client can make requests for resources such as HTML pages, images, and videos, and the server returns the requested resource in the response. HTTP supports various methods such as GET, POST, PUT, DELETE, etc. which determine the type of action the client wants to perform.

HTTP is a stateless protocol, which means that each request and response is treated as an independent transaction, and the server does not maintain any information about previous requests. This makes HTTP a scalable and efficient protocol for transmitting data over the internet.

HTTP REQUEST

HTTP requests consist of several components including:

  1. Request Method: The request method indicates the type of action the client wants to take, such as GET, POST, PUT, DELETE, etc.

  2. URI (Uniform Resource Identifier): The URI identifies the resource the client wants to access or the endpoint where the data is to be sent.

  3. HTTP Version: The HTTP version indicates which version of the HTTP protocol the client is using.

  4. Request Headers: Request headers contain additional information about the request, such as the type of content being sent, the content length, and the preferred language of the response.

  5. Request Body: The request body contains the data that is sent to the server in the case of POST or PUT requests.

  6. Query String: The query string is a string of characters appended to the URI to provide additional information to the server, such as search terms or filter criteria.

HTTP RESPONSE

HTTP requests consist of several components including:

  1. Request Method: The request method indicates the type of action the client wants to take, such as GET, POST, PUT, DELETE, etc.

  2. URI (Uniform Resource Identifier): The URI identifies the resource the client wants to access or the endpoint where the data is to be sent.

  3. HTTP Version: The HTTP version indicates which version of the HTTP protocol the client is using.

  4. Request Headers: Request headers contain additional information about the request, such as the type of content being sent, the content length, and the preferred language of the response.

  5. Request Body: The request body contains the data that is sent to the server in the case of POST or PUT requests.

  6. Query String: The query string is a string of characters appended to the URI to provide additional information to the server, such as search terms or filter criteria.

HTTP 0.9

The first HTTP version had no version number; it was later referred to as HTTP 0.9 to set it apart from subsequent versions. Requests started with the only available method, GET, and the path to the resource, making HTTP/0.9 incredibly easy to use. Since the protocol, server, and port were not required once connected to the server, the complete URL was omitted.

As was previously mentioned, the initial version of HTTP only permitted information retrieval from a server. However, as the Internet developed and new features emerged, it grew to be inadequate.

HTTP 1.0

In this case, the HTTP protocol's version 1.0 was introduced in 1996, roughly five years after version 0.9.

The HTTP protocol now has several additional tools in version 1.0. Here are a few of them:

An HTTP 0.9 request's header merely contained the resource name and the method. As a result of the introduction of the HTTP header in HTTP 1.0, the protocol became versatile and expandable by enabling the transport of metadata.

Versioning: By adding it to the request line, HTTP requests explicitly state the version that is being used.

HTTP answers now include a status code, allowing the recipient to see how the request is progressing (successful or failed)

Content-type: Because of the Content-Type field in the HTTP header, HTTP can send documents other than basic HTML files.

New techniques: In addition to GET, HTTP 1.0 offers two new techniques (POST and HEAD)

HTTP 1.1

Only a year after version 1.0, HTTP version 1.1 was made public in 1997. The addition of various extensions makes HTTP 1.1 an improvement over HTTP 1.0.

We can list the following improvements as some of the most significant:

Host header: The host header is not formally required by HTTP 1.0. It is required by the specification for HTTP 1.1. To identify between domains that point to the same IP address when messages are routed through proxy servers, the host header is especially crucial.

Persistent connections: In HTTP 1.0, a new connection must be established for each request/response pair. With HTTP 1.1, many requests can be processed on a single connection.

Continue status: Clients can now provide simply the request headers in the beginning and check to see whether they receive a continue status code to prevent servers from rejecting unprocessable requests (100)

Six new methods were introduced to HTTP 1.1 in addition to the ones that were already present in HTTP 1.0: PUT, PATCH, DELETE, CONNECT, TRACE, and OPTIONS.

In addition to the improvements mentioned above, version 1.1 of HTTP also includes a number of other additions including compression and decompression, multi-language support, and byte-range transfers.

HTTP 2.0

About 18 years after HTTP 1.1 was initially launched, HTTP version 2.0 was finally made public in 2015. HTTP 2.0 in particular concentrated on enhancing protocol performance.

To do that, HTTP 2.0 incorporated a number of enhancements to enhance connections and data transfer. Here are a few of them:

Multiplexing requests: The HTTP 1.1 protocol is sequential. In this way, we can send a single request. Asynchronous requests and answers are also possible with HTTP 2.0. By doing so, we can execute several requests concurrently over a single connection.

Prioritizing requests: With HTTP 2.0, we may assign a numerical priority to a batch of requests. Consequently, we can specify the sequence in which we anticipate replies, such as expecting a webpage's CSS before its JS files

HTTP 3.0

In contrast to earlier HTTP versions, which were/are Request For Comments (RFC) documents of the Internet Engineering Task Force, HTTP 3.0 is an Internet-Draft (IETF). In 2020, the first draught was released.

The transport layer protocol used distinguishes HTTP 2.0 and HTTP 3.0 most significantly. There are TCP connections with or without TLS in HTTP 2.0. (HTTPS and HTTP). In contrast, HTTP 3.0 is built on top of QUIC (Quick UDP Internet Connections).

Similar request methods, status codes, and message fields are used by HTTP/3 in comparison to earlier iterations of the protocol, but they are encoded and session state is maintained in a different way. But as compared to earlier versions, HTTP/3 has lower latency and loads more quickly in real-world usage: in some circumstances, it is over three times faster than HTTP/1.1. This is partly because the protocol adopted QUIC (which remains the only HTTP version deployed by many websites).

QUIC is a transport layer protocol with native multiplexing and integrated encryption, to put it briefly. In addition to being able to minimise latency issues in lossy and poor connections, QUIC offers a rapid handshake process.