How Browsers work?
World Wide Web works on the client-server model. A user computer works as a client which can receive and send data to the server. When a web page is requested by a user, the browser contacts the requested server (where the website is stored) and by fetching and interpreting the requested files, it displays the web page on the computer screen.
Although working of the browser is not as simple as it seems, since a plenty of internal tasks are performed before a webpage appears on the screen. The whole process takes place in these three steps:
1. Contact to DNS Server - When a user enters a URL into the address bar and hits ‘enter’, at first browser contacts the DNS server. A DNS server stores the IP addresses of the server associated with the corresponding domain names. The DNS server takes the domain name from the browser and returns the corresponding IP address to the browser.
2. Contact to Server – After getting the IP address of the server for the requested webpage, browser sends a request to that server for the desired files. For example consider the following URL :
This URL is divided into three parts. First one is HTTP – it is a protocol named Hyper Text Transfer Protocol which defines the way browser communicates with the server. The second part is www.engineersgarage.com which is translated by the DNS server with the IP address. It is the address of a computer (Web Server) where the requested web page is stored. The third part is ‘articles’ which tells the address of the file that is located in the root folder of the website.
HTTP protocols are used to transfer the webpage named ‘articles’ to the browser. The protocol decides the format as well as the methods of communication between web client and server.