This is how the Internet works in 10 mins

Andreas Lymbouras
9 min readMay 23, 2019

--

Internet. When you stop and think about it is pretty miraculous.

It’s essentially communication between electronic devices! That’s all it is.

But how is this communication happening?

Human communication

We, humans, understand each other through a language. Since the day we are born we learn words and the rules that dictate a language. This way we can express our inner feelings, and our logical conclusions with each other.

The brain instructs the mouth to start sending sound waves and on the other end, the ear receives those waves and converts them into electrical signals for its brain to interpret.

The medium of transportation is usually the air.

But those waves can lose their strength, for various reasons, if the distance between the two people is long enough.

That’s why we need to do better.

Machines

You can think of devices connected to the Internet as a powerful tool that empowers you. It’s your superpower! In the palm of your hands, you have a device that can send all kinds of information to people who have the same superpower in their hands! You can now answer questions, video conference, send messages and images to millions of people!

How is this happening though?

Well, devices are communicating in a way similar to us!

To understand this let’s first talk about the information they are sharing.

Information

Machines are like a human brain. They have short-term memories (RAM), long-term memories (hard disk or SSD) and logical/mathematical calculations (CPU).

Just like our brain uses electrical and chemical signals to store and process information, devices as well store and process information in an electronic way.

All this information is made of bits!

A bit can be described as “on” or “off”. We typically use a “1” meaning “on” or a “0” meaning “off”.

For example, the two values of a bit can be represented by two levels of electric charge stored in a capacitor. (“0” is when voltage is below 0.4 and “1” is when its higher than 2.4 volts)

Eight bits strung together makes one byte. 1024 bytes all together is a kilobyte(KB), 1024 kilobytes is a megabyte(MB), etc.

A song is typically encoded using about three to four megabytes. That’s almost 33.5 million bits!

SSD 660p series. It can store up to 1 TB of data. That’s almost 1.1 trillion bytes = 8.8 trillion bits in one chip!

It doesn’t matter if it’s a text, picture, video, or a song. Everything in the machines’ world is represented and sent around as bits. These are the atoms of information!

Now back to the Internet.

You might ask, how are all those bits being transferred from one machine to another?

Yeah sure external disks and USBs are a way, but we can do better and faster than this!

Bits can be represented in many ways. Apart from electricity, light intensity and electromagnetic waves can also represent a bit!

The medium of transportation for electric voltage is the ethernet copper wires. However, you see lots of signal loss over just a few hundred feet. So, if we really want this Internet thing to work over the entire world, we need a different way of sending this information on long distances.

We can actually send bits as light beams from one place to another using a fiber optic cable. We are sending bits in the speed of light! That’s about 300 million meters per second. That’s really fast! You can’t really estimate it but when you hit that enter button to get a website, the information (bits) are traveling thousands of kilometers to reach your device in milliseconds!

Because we can go hundreds of miles without signal loss, we use fiber optic cables across the ocean floors to connect one continent to another.

Underwater Internet cables

Side note:

We take this Internet thing for granted but it’s really a pretty fragile physical system.

In 2008 there was a cable that was actually cut near Alexandria, Egypt, which really interrupted the Internet for most of the Middle East and India.

Another side note:

Amazon, Facebook, Google, and Microsoft have their own underwater cables.

Underwater fiber optic cables. Yellow ones are owned by Facebook, Google, Amazon, or Windows

Wireless (WiFi, 5G) machines typically use radio signals to send bits from one place to another.

The transmitter machine has to actually translate the binary ones(1s) and zeros(0s) into radio waves, while the receiving machine reverses the process and converts it back into binary for your computer.

Radio waves to digital binary representation

So, wireless has made our Internet mobile, but a radio signal doesn’t travel all that far (just about 20–30 meters) before it completely gets altered.

If you were about to see all these waves with the naked eye, it would look like this:

Internet Radio signals. left: WiFi pulses of waves. right: 4G radio signals

The physical method for sending bits may change in the future.

Whether it is higher frequency radio waves, lasers sent from satellites, balloons or drones.

Top left: Loon Project by Google. Top right: Facebook’s Internet-beaming drone. Bottom: Sattelite plans for Internet everywhere around the globe

But the underlying binary representation of information and the protocols for sending that information and receiving that information have pretty much stayed the same.

Everything on the Internet whether it’s text, emails, images or videos all come down to these ones and zeros being delivered by electronic pulses, light beams or radio waves.

Brain neurons send info

Neurons communicate via the Synapse. Information from one neuron to another flows across a small gap called a synapse. At the synapse, electrical signals are translated into chemical signals in order to cross the gap.

Neurons connect and communicate with each other via the synapses

And just like the brain uses neurons and synapses to send information, our devices do the same as well!

You can think of the Internet as a huge brain where devices are the neurons. Those devices/neurons send bits to other devices/neurons. Special devices (transmitters, routers) act like brain synapses; they convert bits to and from the various bit representations (electricity, light intensity or electromagnetic waves).

So far so good. We got it; bits are transferred from one machine to another. How do they know where the destined machine is located?

IP Addresses & DNS

All the devices on the internet have unique addresses. An address on the internet is just a number, just like a phone number, that’s unique to each device on the network. This is similar to homes’ addresses. You don’t need to know the person to send them a letter, but you do need to know their address so that the letter can be carried by the mail system to its destination.

But wait, you don’t know any address of any other device!

Well, a system called DNS (Domain Name System) associates human-readable names like www.example.com with their corresponding IP address. Your device and the DNS servers communicate, behind the scenes, using their own protocol.

But of course, there are hundreds of DNS servers, in countries around the world, that handle billions of requests per day.

Routing

Even though it seems like your computer connects directly to servers on a direct, dedicated line, this is not how the internet works. If the internet was made of direct, dedicated connections, it would be impossible to keep things working for the millions of users. Imagine if a wire breaks down, the Internet would have lots of latencies and failures.

Instead, data travels on the internet in a much less direct fashion. Data on the Internet is broken down into multiple packets of information. A packet travels from one place to another on the Internet a lot like how you might get from one place to another in a car. Depending on traffic congestion or road conditions, you might choose or be forced to take a different route to get to the same place each time you travel.

Breaking down data into multiple packets makes the Internet more efficient. And that’s because if a packet of information gets lost, the sending device doesn’t need to resent the whole data, it just needs to send the lost packet.

Also, having options for paths makes the network fault-tolerant. Which means tolerant of different kinds of failures like wires, routers, or even congestions. Red lines below represent those failures.

Red paths are congested paths, so packets are using alternative paths. Image from code.org

What if a packet gets lost? Will I still get my data?

TCP (Transmission Control Protocol) manages the sending and receiving of all your data as packets. Think of it as a guaranteed mail service. When your packets arrive, TCP does a full inventory check and sends back acknowledgments of each packet received. If all packets are there, TCP signs for your delivery and you’re done.

If TCP finds out that some packets are missing, it won’t sign, because otherwise your web image, page or voice would have missing parts. For each missing or incomplete packet, the server resends them.

TCP protocol & routing

How do machines talk to each other? What’s their communication like?

HyperText Transfer Protocol (HTTP)

What actually happens when you type an address and hit enter?

At that moment your device asks another device (called server) for a website (a special file that web browsers can interpret).

The language of this type of communication is called HTTP protocol. It is the language that one computer uses to ask another computer for a document.

If you were about to intercept the conversation between your computer and a web server on the Internet you would see GET or POST requests which look something like this:

GET /login

Which is essentially requesting the file called “login”. For the web, all these documents are actually coded in a programming language that web browsers (like Chrome or Firefox) understand. And this is all about the design of the page, how the page looks like (the positioning and the way buttons and images look in your monitor).

If you noticed above I bolded the words “this type” because there are many kinds of communications (protocols) that can happen between machines.

SMTP, for example, is another communication protocol for e-mail transmission.

A protocol is a well-known set of rules and standards, that if all parties agree to use it, will allow them to communicate without trouble.

The really interesting thing about the Internet is that in order for a new technology to use it in some fashion, it just needs to know which protocols to work with. This architecture is very powerful because users don’t really need to care about how the Internet physically works.

The whole Internet. OPTE Project Map of the Internet as of 2005

Conclusion

Internet is, by all means, one of the greatest inventions of all times and you are lucky to witness its evolution.

It has the potential to push humanity and innovation further at an exponential pace. And that’s because we have the power to share ideas and knowledge in a fast way.

Historically, people who had access to information were in a more advantageous position than those who didn’t.

Information is power indeed. But how you use it is more important.

You now have access to a plethora of information (2.5 quintillion bytes of data are being created per day). But how you use it is what makes you wise. Information is just raw data, knowledge is processing and understanding the data and wisdom is the ability to judge which parts of knowledge is true and right for you and as a result apply them to your life.

So, choose wisely what kind of information you are feeding your brain with, as well as to whom and how much information you are giving.

With billions of devices connected to the Internet these days, huge amounts of data are being used to analyze and make informed decisions worth billions of dollars.

That’s why information is rightfully given the title of the most valuable asset of our times!

IoT exponential connected devices

--

--

Andreas Lymbouras

Software engineer. BNP Paribas application developer & co-founder at CrowdCompute crowdcompute.io/