Preface: Do you really understand your daily Internet use?Imagine that you are hungry, so you open your phone and type in "fried chicken takeout" , then a bunch of food pictures pop up, and a few minutes later the fried chicken is delivered to you. But have you ever thought that in just these few seconds, your request has undergone a mysterious journey "across half the world" ? How does this happen? You type the URL into your browser, hit enter, and then what? Don't worry, today we will use the most easy-to-understand way to show you the magic behind every time you go online ! (No computer knowledge is required, you will understand it in seconds!) Step 1: Your browser needs to find a "path" You open your browser, type in So, it has to first ask the "Internet's phone book" - DNS (Domain Name System):
( PS : If the DNS resolution is slow, you will feel that the web page loads slowly.) Step 2: Data "courier" picks up the package at your doorYour computer has to send the request (HTTP request) to the Baidu server. At this time, the courier - TCP/IP comes into play. TCP (Transmission Control Protocol) is like a rigorous deliveryman. It is not sloppy. Every time it transmits data, it will say:
This process is called a three-way handshake , which is used to ensure the reliability of data transmission, just like when you confirm with the merchant before shopping online: “Do you really have the product?” → “I do!” → “Okay, I’ll place an order!” Step 3: Data packaging and express deliveryAfter it is confirmed that it is connected, your HTTP request (such as "I want to visit the Baidu homepage") will be packaged into multiple small notes (multiple data packets) and transmitted through various means such as network cables, WiFi, optical fibers, satellites, etc. Each packet has its own "ID card":
These packages will pass through countless routers (express transfer stations) , each of which will look at "where this package should go" and then help forward it to a place closer to Baidu. Imagine you place an order in Beijing to buy lychees from Guangdong:
Data is transmitted in this way through one stop after another. Step 4: Baidu server receives the request and starts "cooking"When Baidu's server receives your HTTP request, it will perform the following steps:
Baidu is like a restaurant:
Step 5: Data return, page assemblyThe data return process is similar to that of sending data, and it will return to your computer along the same route. But at this time, the webpage is not displayed completely at once, but:
If you feel that a web page is loading slowly , it may be because:
Step 6: You see the complete web page!After all data transmission is completed, the browser can show you the complete web page ! You may think, "Huh? It seems like nothing happened", but a network magic is actually done behind the scenes . Summary: The whole process from entering the URL to displaying the web page
Actual Demonstration: You can also see the data transfer yourself!Want to see what your network requests look like? You can do this:
ConclusionNext time you open a web page, don't think it just appeared out of thin air! Every time it loads, it's a mysterious interaction between your computer and servers around the world . Today, we use a simple and interesting way to show you the basic process from inputting a URL in the browser to displaying the page , hoping to give you a general understanding of the mechanism behind web page loading. However, in order to make it easy to understand, we only talked about the overall process and did not go into more detailed parts, such as the specific process of DNS resolution, the details of the TCP three-way handshake, how data packets are transmitted in fragments, how network communications are layered, and how the browser parses HTML/CSS/JS step by step to render a complete page , etc. |
EtherNetservers is a foreign hosting company esta...
Recently, the official website of the Ministry of...
In June 2019, the Ministry of Industry and Inform...
With the rapid development of information technol...
While the concept may seem simple in theory, the ...
The popularity and application of 4G has opened t...
[[332143]] This article is reprinted from the WeC...
From February 27 to March 2, MWC 2023 (2023 Mobil...
V.PS recently launched two Nano series VPS packag...
Nowadays, many people ask the question, is data d...
If we distinguish by telecommunications scale, th...
Labs Guide URLLC "Low Latency High Reliabili...
[[183847]] There is a distinct difference between...
Friendhosting has launched this year's Black ...
V5.NET suspended new orders for the backend upgra...