What happens when you enter a URL in your browser’s address bar?

Kashish Yadav
2 min readNov 8, 2020

--

In this age of internet, we’re bombed with websites all around us. From shopping to studying to reading….everything is now just a click of a button away! All we have to do is type in a website’s URL. A URL you ask? Well, a website’s address in the laymen’s terms, or a “Uniform Resource Locator” if want to sound fancy. We all know how to use the internet to get to a website, but do you know HOW it all folds out behind the scenes?

This is how- When you type in a URL in your browser, your browser checks for cache in a DNS entry for the website’s corresponding IP address. A DNS(Domain Name System) is like a phonebook, but for websites, it maintains and maps the names of the websites. So your browser checks for cache in different places, until it find the entry — it checks for Browser cache, Operating System, then Router cache and ISP cache. If not found in cache, ISP’s DNS server initiates a DNS query to find the IP address of the website. These requests are basically small data packets that contain information content of request and of course, the IP address.

Your browser then initiates a TCP connection with the server using synchronize (SYN) and acknowledgement (ACK) messages. Browser then sends an HTTP request to the web server, a GET or POST request. Server (on the host computer) receives the request and sends back a response. The response is assembled in a format like JSON, XML or HTML. Server sends out HTTP response along with the status. Browser then finally displays HTML content. Voila! The job’s done.

Thank you for reading ! :)

--

--