Internet 101

Photo by John Schnobrich on Unsplash

No matter which role you wanna work in, frontend or backend developer, the concept of Internet is always fundamental and it’s something you cannot miss. So, let’s start answering these questions.

source: https://roadmap.sh/roadmaps/backend.png

In this page, I’m not gonna answer these questions in deep as each question indeed can lead to other questions. If I have time, I’ll definitely write another page for individual question in detail.

Before understanding how the internet works, let’s deal with the concept of Internet first.

Internet is the network of hundreds and thousands of networks.

Network is the interconnections of computing devices, including routers and switches. They’re interconnected by wires or wireless.

The whole internet works by sending data packets to transmit information using different kinds of protocols (e.g. TCP, UDP, etc).

Protocol is a set of rules that define:

  1. formats of data packets,
  2. order of messages sent and receive among the devices,
  3. actions taken on message transmission

There are many types of network protocols. The most common protocols are TCP, UDP, HTTP, DNS, FTP, SMTP, etc.

HTTP(Hypertext Transfer Protocol) is an application protocol. By default, the port number of HTTP server is 80.

A web page consists of the base HTML file with many objects (e.g. images, audio files, etc). Each object is addressable by a URL.

HTTP follows the client/server model. The client(browser) send requests to the server for web content and the web server send objects back to the client in response to the requests.

A browser is exactly the client that I’ve covered in the previous HTTP section. It’s a tool that takes you anywhere on the internet, allowing you to see anything (e.g. text, images, video) around the globe.

In short, it sends requests to the web server and retrieves information from the responses and shows it on your desktop or your phone.

Actually, a browser uses TCP to establish the connection for sending requests and receiving responses. Here is the detailed process of how browser works:

  1. browser initiates a TCP connection through port 80 of the web server
  2. web server accepts the TCP connection from the browser
  3. browser sends requests and web server sends back the response to exchange HTTP messages
  4. TCP connection is closed

A Domain Name is the name of a website. As it’s hard for human to remember the IP addresses (strings of long numbers), that’s why the domain names were developed and every domain name is linked to one or multiple IP addresses. This helps us to find and get to servers on the Internet easily.

Analogy: It’s like people’s name linking to their telephone numbers

DNS(Domain Name System) is an application-layer protocol that provides a name-address mapping service. It’s a rule for computer devices(host, routers, name servers) to communicate and resolve IP addresses from the domain names.

DNS is distributed database implemented in hierarchy of many name servers. DNS servers can be classified into Root name servers, Top-level domain (TLD) servers and Authoritative servers.

Let’s take www.google.com as an example. Here is how DNS works:

  1. client queries a root name server to ask for where the com DNS server (TLD server) is
  2. client queries the com DNS server to get the google.com DNS server (authoritative server)
  3. client queries the google.com DNS serve to obtain the IP address of www.google.com

Web Hosting is a service for everyone including individuals and organisation to put a web page onto a web server for others to access. It is like a house where your website stays and all websites on the internet, need web hosting.

Web Hosting Service Providers are companies that provide the servers for you to host a website. Some are free and some are charged. For static websites, there are hundreds and thousands of options for web hosting. For example, S3 from AWS (Amazon Web Services), Github Pages, Netlify. Personally, I love using Netlify for my personal website as it can be linked with repo hosting websites like Github and Gitlab and my website can be updated automatically every time I push a commit.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store