What is HTTP: Components and Characteristics

What is HTTP: Components and Characteristics

8 mins read2.9K Views Comment
clickHere
Jaya
Jaya Sharma
Senior Executive Content
Updated on Nov 7, 2022 18:18 IST

HTTP is an application protocol that has been in use for the transmission of hypermedia documents. While it was initially designed for communication between web browsers and servers, it can be used for other purposes as well.

2022_11_MicrosoftTeams-image-83.jpg

In this article on ‘What is HTTP’, we will discuss this application protocol in detail along with its characteristics, advantages, and disadvantages.

Table of Contents

What is HTTP Protocol?

Hypertext Transfer Protocol (HTTP) is an application layer protocol that is used for loading web pages consisting of hypertext links. It is designed within the framework of Internet Protocol Suite. This protocol aims to transfer information among network devices. It runs on top of other layers of the network protocol stack. It is used for transferring data in the format of audio, video, hypertext, and plain text. Hypertext Transfer Protocol has a client-server architecture. It allows the reliable transfer of resources between the web application server and the user agent. 

Check out computer networks

In the client-server network model, it functions as the request-response protocol. The client submits the request message to a server. The server processes the request and, in turn, provides resources and performs several functions on behalf of the client. It then returns a response message to the client. The response message consists of a status line, headers, and sometimes a body containing requested data. Between the client and server, there are various entities, called proxies, that perform different operations and act as caches or gateways.

Explore free networking courses

Different Versions of Hypertext Transfer Protocol

Following is the timeline of different versions of Hypertext Transfer Protocol:

  1. HTTP/0.9: This version of HTTP has now become obsolete. Earlier, this was written as a plain document. It had a limitation of only supporting the GET method but not other formats. Due to this, clients could only retrieve HTML documents, but it neither supported nor allowed information upload in other file formats.
  2. HTTP/1.1: Most major web browsers and web servers started implementing the new features of HTTP in 1996. These features were as per the specifications of pre-standard HTTP/1.1 drafts specifications.
  3. HTTP/2: Originally, it was known as HTTP 2.0. It is a standard HTTP protocol that is used by the World Wide Web. It is highly compatible with the HTTP method, status codes, most header fields, and URLs of HTTP /1.1.
  4. HTTP/3: It is the latest version of the Hypertext Transfer Protocol that complements both HTTP/1.1 and HTTP/2. Rather than relying on TCP, it uses QUIC, which is a multiplexed transport protocol that is built on UDP. It has lower latency and quick load time in comparison with previous versions. 
How does HTTP work?
How does HTTP work?
Almost every URL that you use starts with HTTP or HTTPs. Have you ever wondered what it is and how does it work. This blog will help you understand how...read more
What is the Difference Between HTTP and HTTPS?
What is the Difference Between HTTP and HTTPS?
HTTP and HTTPS are both protocols used for transmitting data over the web, but they have a crucial difference concerning security.
URI vs URL | What’s the Difference?
URI vs URL | What’s the Difference?
The primary distinction between URI vs URL is that a URL is a locator, which means it contains the information necessary to find a resource on the internet. Whereas a...read more

Characteristics of HTTP

The following are the features of Hypertext Transfer Protocol:

  1. This is a stateless protocol since both client and server know each other during the current request only. Due to this, both client and server do not retain information between various requests of web pages.
  2. It is designed as a connectionless protocol to allow server resources to be equally shared by clients across the world. 
  3. The connection between clients and server exists during the current request and response time only.
  4. It is media-independent in nature since data can be sent when both the client and server ways to handle data content. Both client and server must specify the content type within the MIME-type header.
  5. It is a stateless protocol since every request is executed independently without knowledge of HTTPS requests earlier executed. 
  6. Latency is the amount of time consumed by the user making a request to the server responding to the user. Since no handshaking is required for subsequent requests in HTTP/3, latency is reduced in Hypertext Transfer Protocol. 

Components

In an HTTP-based system, there are four main components, including the Client, Proxies, and Server. Let us discuss these components one by one. 

  • Client: It is a user agent that initiates the request. For displaying a web page, the browser will send an original request to fetch HTML documents that will display the web page. It will parse this file and make an additional request that corresponds to execution scripts and sub-resources that are contained within the pages.
  • Proxies: Between the web browser and server, several computers and machines relay HTTP messages. Due to the layered structure of the web stack, many operate at transport, physical, and network levels. Those operating at application layers are known as proxies.
  • Web server: This exists on the opposite side of the communication channel that serves the requirement of the client. Virtually, it may appear as a single machine, but in reality, it is a collection of servers that share the load. It may also consist of complex pieces of software that interrogate other computers which partially or totally generate the document on demand. 

Transactions in HTTP

For accomplishing a single task, an application issues multiple HTTP transactions. For instance, browsers use a transaction to fetch HTML ‘skeleton’ for describing the page layout while others for displaying graphics-rich web pages. Due to the cascade of these transactions, it is known as the collection of resources instead of a single resource. 

These transaction consists of HTTP request and response. Here, the client sends a request message to the server to initiate a transaction. The server then replies to this request message by sending a response message. This communication takes place with the help of formalised data blocks called HTTP messages. Let us learn about these factors within the transaction in detail. 

HTTP Request

This request carries a series of encoded data that carries different types of information. A request consists of HTTP version type, HTTP method, URL, request headers and HTTP body which is optional. 

  1. HTTP method or HTTP verb: This indicates the action that HTTP request expects from the queried server. ‘GET’, ‘PUT’, ‘DELETE’ and ‘POST’ are some of the popular HTTP methods. 
  2. HTTP headers: These consist of text information that is stored in key-value pairs and are included in each HTTP request. They are used in HTTP requests for providing information about request context to help the server tailor its response. 
  3. Uniform Resource Locator (URL): It is a unique identifier that specifies the location of a resource on the internet. It consists of a protocol and domain name that helps in identifying how and from where to retrieve a resource. 
  4. Version: This part helps in identifying the HTTP version being used in the request.

Explore Free Online Courses with Certificates

HTTP Response

Server provides an HTTP response to web servers to provide them with requested resources. These responses consist of status code, response headers and a body that is optional. Let us discuss each one of them one by one. 

  1. Status code: This is a  three-digit code that is used for indicating whether a request has been completed or not. These codes start with 2 to indicate that the request has been properly completed. When a response starts with 4 or 5, it indicates that there is an error and that webpage will not be displayed. 4 indicates client-side error and 5 indicates server-side error. 1 refers to informational response and 3 means redirect. 
  2. Response header: Just like the request header, the response also has headers that consist of information such as the language and data format being sent in the response body. Through this information, the client can also learn about the server that has sent the response. 
  3. Status Message: It is a non-authoritative and short description of the status code. Servers always return a message for each request. 

Advantages of Hypertext Transfer Protocol

The following are the advantages of Hypertext Transfer Protocol:

  1. It helps in fetching not only hypertext documents but also media like videos and images. 
  2. Enables easy communication among devices and applications on the web. 
  3. It is extensible in nature since clients and servers may agree to add on new field names and information to suit their needs. 
  4. Reduces network congestion as there are very few TCP connections. 
  5. It is a text-based protocol that is simple and readable for users. This allows easier testing for developers, which, in turn, reduces complexity for newcomers. 
  6. Enables receiving applications to quickly open the incoming file. 
  7. It eliminates the need to ask the sender about applications that are required to read or view file content. 
  8. The method in which documents can be cache and for how long is controlled by Hypertext Transfer Protocol. It can help clients instruct cache proxies to ignore the stored document. 
  9. To prevent privacy invasions, web browsers enforce strict separation between websites. Due to this, only pages of the same origin can access each other’s information. HTTP headers help in relaxing this strict separation on the server side. 

Disadvantages

HTTP has the following disadvantages due to which its popularity has gone down:

  • It is difficult to confirm if the web server sending the request is the same one that has returned the response. This increases the probability that the client may be spoofed.
  • There is difficulty of blocking Dos attacks under massive requests.
  • Since it cannot prove the integrity of the message of communication, it is impossible to confirm the request and received response is the same. This allows attackers to intercept and tamper the content while the response is in transit. 

Conclusion

Hope that through this article on ‘what is HTTP’, you will be able to understand its components, applications, and advantages. Since this protocol lacks the security of the message, many applications and web browsers appreciate the use of HTTPS over HTTP. While some of the versions have become obsolete, certain versions are still in use. 

_______________

Recently completed any professional course/certification from the market? Tell us what you liked or disliked in the course for more curated content.

Click here to submit its review

About the Author
author-image
Jaya Sharma
Senior Executive Content

Jaya is a writer with an experience of over 5 years in content creation and marketing. Her writing style is versatile since she likes to write as per the requirement of the domain. She has worked on Technology, Fina... Read Full Bio

Comments