HOW THE INTERNET AND WEB WORKS; A FOUNDATION TO WEB DEVELOPMENT.
Tags: webdev, http, internet, server
Published: 2023-07-09 19:31:42

Let's start by understanding what the Internet is. The Internet is a global network of interconnected computers that allows people from all around the world to share information and communicate.

![Internet](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zoebkp8m4m0hqbk3gwl5.jpg)

It relies on the infusion of special technologies and protocols to function. Without the internet, browsing the Web or reading this article online wouldn't be possible today.

### HOW DO WE ACCESS THE INTERNET?

Accessing the internet has become easier with the development of technology. Gone are the days of slow dial-up modems.  Nowadays, our devices, such as computers, smartphones, or tablets, connect to the internet through different connection methods like Wi-Fi networks or mobile data plans.

![Internet connection](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tuwez89luykxg5xrc61x.jpeg)

Technically, smartphones use their built-in Wi-Fi capabilities to connect to Wi-Fi networks. The Wi-Fi networks are facilitated by gateway routers. These gateway routers help send information from our connected devices to the Internet through ISP (Internet Service Provider).  ISPs are the companies we pay to allow us to assess the Internet.

### BROWSING THE WEB

Now, let's surge further into what happens behind the scenes when we browse the web. The internet connects computers, smartphones, tablets, and other devices together. Hence, to send a message or request to a computer, we need to know its unique address; where to find it. Therefore, any computer connected to a network has a unique address that identifies it. This address is called an IP (Internet Protocol) address. An example looks something like 104.244.42.65.

You may have wondered how it works when we open a web browser like Google Chrome or Safari, type in a website address like www.twitter.com, and press enter. How does it load up all the information on the screen?

_**Note:** "www.twitter.com" is a Domain Name; which is simply a human-readable alias for an IP address. Every domain name is mapped to an IP address in the DNS (Domain Name System)._

Here's what happens: our web browser sends a request to our ISP, asking where to find twitter.com. The ISP receives the request and forwards it to the DNS to find the corresponding IP address for the domain name. Then, the ISP sends the IP address back to our browser.

Now that our browser knows the IP address of twitter.com, it sends another request for data to that address. This request is sent to the Twitter server, in a client-server model, using a special protocol called HTTP (Hypertext Transfer Protocol). HTTP is the foundation of communication on the web. It allows clients like web browsers or applications to exchange information with servers in a standardized format.

_**Note:** A server is a computer that stores and manages information and is always ready to process and share data when you ask for it._

The server receives our request, processes it, and retrieves the requested data, which in the case of twitter.com includes HTML, CSS, and JavaScript files. Then, the server sends this data back to our browser.

In summary, when we type a website address in a browser, it asks our ISP to find the website's IP address. Once the IP address is known, our browser communicates with the server at that address to get the requested information, and then it displays the webpage for us to see when the response data returns.


![How the web works](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iiyxlb9k1vmyz8yg1kvk.png)