DEV Community

Cover image for πŸ™‹πŸ”What happens when you type a URL ? πŸŒπŸ’»
Sujeet vishvkarma
Sujeet vishvkarma

Posted on • Edited on

πŸ™‹πŸ”What happens when you type a URL ? πŸŒπŸ’»

Ever wondered what happens when you type a website name in the browser? πŸ€”πŸŒ It's like telling the internet, 'Hey, take me to the cool stuff!' and a bunch of tech wizards make the magic happen behind the scenes. βœ¨πŸ’» Get ready for a fun journey into the land of web-wonders! πŸš€πŸ‘Ύ

Here's a simple flow diagram of what happens when you type a URL in the browser:

Image description

Here's a Detailed flow diagram

Image description

Certainly! Let's break down each step:
Resolve Domain Name
User enters URL (πŸ‘€): The user triggers the process by entering a URL in the browser, expressing the desire to access a particular website.

Browser (πŸ’Ύ): The browser, acting as the user's gateway to the internet, first checks its cache (πŸ’Ύ) to see if it already has information about the requested domain.

Cache (πŸ•΅β€): If the browser doesn't find the domain in its cache, it turns to the DNS Resolver (πŸ•΅β€) for assistance in locating the IP address.

DNS Resolver (🌳): The DNS Resolver (🌳) plays the role of an internet detective. It queries the root name server to initiate the process of unraveling the IP address associated with the requested domain.

Root Name Server (πŸ›οΈ): The Root Name Server (πŸ›οΈ) directs the DNS Resolver to the Top-Level Domain (TLD) Name Server, providing a starting point for narrowing down the search.

TLD Name Server (πŸ›οΈ): The TLD Name Server further guides the DNS Resolver, redirecting it to the Authoritative Name Server that holds information about the specific domain.

Authoritative Name Server (πŸ›°οΈ): The Authoritative Name Server (πŸ›°οΈ) holds the key to the kingdom, providing the DNS Resolver with the actual IP address associated with the domain.

DNS Resolver (πŸ›°οΈ): The DNS Resolver takes this newfound knowledge and joyfully delivers the IP address back to the browser, completing the domain resolution process.

Initiate Request
Browser initiates TCP Connection (🀝): Now armed with the IP address, the browser establishes a hearty handshake (🀝) through a TCP connection with the server housing the requested website.

Browser sends HTTP Request (πŸ“¨):

Method: GET

URL: example.com

Host: example.com

Other headers: Alongside the basic request, additional headers convey extra information to the server.

Handle Response
Server receives HTTP Request (πŸ“₯): The server, receiving the browser's heartfelt request, prepares to process the incoming HTTP request.

Server generates HTTP Response (πŸ“€):

Status Code: 200 OK

Content Type: HTML

Other headers: The server constructs a detailed response package, including status information, content type, and other relevant headers.

Body of the response (HTML code): Within this package lies the treasure - the HTML code that constitutes the content of the requested webpage.

After Response
Browser receives HTTP Response (πŸ“₯): The browser, eager and attentive, welcomes the response from the server.

Browser parses HTML code and renders the web page (🎨): The HTML content undergoes a transformation as the browser interprets and renders it into a visually appealing web page (🎨) for the user to explore.

This detailed breakdown encapsulates the journey from entering a URL to experiencing the rendered web page. If you have specific aspects you'd like to explore further or if there's anything specific you'd like to add, feel free to let me know!

Conclusion:
So, there you have it, the secret sauce behind typing a website into your browser! It's like sending a little message to the internet fairies, who work their magic to bring you the coolest stuff. Remember, every time you hit enter, you're unleashing a digital adventure. Happy browsing, internet explorer! 🌐✨

Call to Action: If this web-journey intrigued you, don't forget to hit that like button and share your thoughts in the comments below. πŸ€—πŸ‘ Your support keeps the digital magic alive! follow for more fun tech tales and become part of our internet explorer squad. Let's ride the web waves together! πŸš€πŸŒŠ #WebAdventure #TechMagic #LikeCommentSubscribe

Top comments (2)

Collapse
 
dumebii profile image
Dumebi Okolo

Thank you so much for sharing!

Collapse
 
sujeet profile image
Sujeet vishvkarma

Dumebi Okolo, thank you for sharing your thoughts! I try to post more content like this