If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content

The Internet protocol suite

As we've seen over the course of this unit, there are many protocols that power the Internet. Each protocol operates at a different layer, building functionality on top of the layer below it.
The layers of Internet protocols are often visualized in a diagram like this:
A diagram of the Internet protocols suite with four layers. From top to bottom:
  • Application layer: includes boxes for HTTP, DNS, and TLS.
  • Transport layer: includes boxes for TCP & UDP.
  • Network layer: includes a single box for IP (v4 and v6).
  • Link layer: includes boxes for Ethernet & Wireless LAN.
That diagram is by no means complete. There are many more protocols in the Internet protocol suite—especially at the application layer—such as SMTP for sending email and FTP for uploading files.
Let's review protocols at each layer and their contributions to the Internet.

Layer by layer

At the bottom layer, two computing devices need a physical mechanism to send digital data to each other. They send electromagnetic signals either over a wired or wireless connection and interpret the signal as bits. The type of physical connection affects the bit rate and bandwidth.
An illustration of two computers connected to each other with a wire. The wire shows alternating electrical signals (high and low) corresponding to labeled binary digits (1 and 0).
Once a network is bigger than two computers, we need addressing protocols to uniquely identify who is sending data and who should receive the data. Every node on the Internet is identified with an IP address.
An illustration of three laptop computers, each labeled with an IP address.
The route between any two computers on the Internet isn't just a straight path from A to B. The data must pass from router to router until it finally reaches its destination, a strategy that comes from the Internet routing protocol.
An illustration of the Internet routing protocol. Two computers are on either side of the illustration and a network of eight routers are between them. Green arrows trace a path from the left computer, through 5 routers, to the right computer.
Data needs to be broken up into small packets, which are then reassembled at the destination. The Transmission Control Protocol (TCP) is used to ensure reliable transport of those packets, with sequencing, acknowledgement, and retries. A faster but less reliable transport protocol is the User Datagram Protocol (UDP).
An illustration of the Transmission Control Protocol. Two computers are shown with arrows going back and forth. The arrow going from left to right is overlaid with binary data labeled as "Sequence #1" and the arrow going from right to left is overlaid with a thumbs up.
There are many uses for the data flowing around the Internet, such as sending emails, uploading files, or chatting online. The most common use of the Internet is the World Wide Web, with its millions of publicly viewable websites, all made possible due to the HyperText Transfer Protocol (HTTP). We can visit a website by typing a domain name in the browser address bar, since the browser knows how to turn the domain into an IP address using the Domain Name System (DNS).
An illustration of the HyperText Transfer Protocol. A laptop computer is shown on the right with a web browser that's visiting the URL "http://www.example.com/index.html". A server is shown on the left, labeled with the domain name "www.example.com". An arrow goes from right to left, overlaid with "HTTP/1.1 200 OK".
When the data contains private information, it needs to be transported securely from the sender to the destination. The Transport Layer Security (TLS) protocol uses algorithms to encrypt the data, while certificate authorities help users trust the encryption.
An illustration of the certificate chain of trust. Starts with an icon labeled "user" on the left. There's an arrow labeled "trusts" from user icon to an icon of a smartphone labeled "client" . Another arrow labeled "trusts" flows from client icon to an icon of a computer labeled "certificate authority". A final arrow flows from certificate authority icon to an icon of a computer labeled "server".

A protocol stack

When a message is sent through the Internet, it doesn't use every protocol in the suite. It does use at least one protocol from every layer, however.
When you're loading a webpage from a domain your browser has never visited before, your browser may need to make a DNS request. This stack of protocols is used when a DNS request is sent through the Internet:
A diagram of the Internet protocols suite with four layers. From top to bottom:
  • Application layer: includes a box for DNS.
  • Transport layer: includes a box for UDP.
  • Network layer: includes a single box for IP (v4).
  • Link layer: includes boxes for Ethernet & Wireless LAN.
Then your browser will make an HTTP request to fetch the webpage. This protocol stack is used when an HTTP request is sent through the Internet:
A diagram of the Internet protocols suite with four layers. From top to bottom:
  • Application layer: includes a box for HTTP.
  • Transport layer: include a box for TCP.
  • Network layer: includes a single box for IP (v4).
  • Link layer: includes boxes for Ethernet & Wireless LAN.
If the webpage is served over HTTPS, then the stack includes multiple protocols at the application layer (both HTTP and TLS):
A diagram of the Internet protocols suite with four layers. From top to bottom:
  • Application layer: includes boxes for HTTP and TLS.
  • Transport layer: includes a box for TCP.
  • Network layer: includes a single box for IP (v4).
  • Link layer: includes boxes for Ethernet & Wireless LAN.

🙋🏽🙋🏻‍♀️🙋🏿‍♂️Do you have any questions about this topic? We'd love to answer—just ask in the questions area below!

Want to join the conversation?

  • starky tree style avatar for user EineName
    Wow, with all of the layers the machines have to use to communicate, I'm just impressed that the internet works at all! (or that it was invented :)).
    (58 votes)
    Default Khan Academy avatar avatar for user
  • starky sapling style avatar for user John Schur
    I may have missed it but I'm not sure how the most efficient server/host route is initially established. Is that done by a general broadcast out through the entire network and then progressively improves the routing efficiency by timing measurements?
    (6 votes)
    Default Khan Academy avatar avatar for user
    • blobby green style avatar for user Abhishek Shah
      Packets may not travel via the most efficient/optimal path. A protocol called Border Gateway Protocol (BGP), however, uses a local broadcast to communicate with nearby nodes and generally forms the basis of how a path is established.

      Since nodes can go online/offline (e.g. Internet outage), the protocol supports changing network graphs. So at any given time, the path constructed by the protocol may not be "optimal".

      Additionally, the idea of "most efficient" depends on the method of comparison. One metric behind the "best" path is timing, but others might be based on shortest physical distance or avoiding inter-ocean/satellite network links.

      Hope this helps!
      (11 votes)
  • male robot johnny style avatar for user Engineering#1
    What is the point of making some protocols "reliable" and some "unreliable", do we have any control over this when we create a new protocol?
    (3 votes)
    Default Khan Academy avatar avatar for user
    • starky ultimate style avatar for user KLaudano
      A reliable protocol is used to ensure every packet is received, but in some cases, it may not make a huge difference if some of the packets are lost and we want to avoid the extra overhead of ensuring reliable delivery. When downloading an application, for example, we need all of the packets, otherwise, the application will not work correctly. On the other hand, if we are in a video chat, we want the audio/video to update in almost real-time and it would be better if the audio cuts out for a split second than if the video chat were to pause for several seconds to wait for the next packet in the sequence.
      (10 votes)
  • hopper happy style avatar for user TimeStop@3
    The text says, "The data must pass from router to router..." I'm assuming this doesn't mean like my router. I googled, and one site says that the packets travel through many different Internet Service Providers. However, there are a lot of contradictions and nonspecific answers. So does anyone know the exact name of the computer that receives and keeps sending packets?
    (5 votes)
    Default Khan Academy avatar avatar for user
  • starky seed style avatar for user Micah Veihmeyer
    How do you change your avatar. I have 10000 energy points but i can't evolve my character
    (4 votes)
    Default Khan Academy avatar avatar for user
  • duskpin ultimate style avatar for user Gracie Wang
    What's the rule of IPv6 addresses?
    (3 votes)
    Default Khan Academy avatar avatar for user
    • male robot hal style avatar for user Abdelrahman
      IPv6 addresses are a type of internet protocol (IP) address used to identify devices on a network.

      They are designed to provide a larger pool of unique addresses than the previous IPv4 standard, which is becoming increasingly depleted. This allows for more devices to be connected to the internet and provides improved security and network management capabilities.

      Additionally, IPv6 addresses support new features and technologies that are not possible with IPv4, such as simpler network configuration, auto-configuration of devices, and better support for mobile devices.
      (3 votes)
  • blobby green style avatar for user natashaonline1111
    Plz correct me if I am wrong: playing an online video game is different from using teh world wide web..right?
    TIA
    (3 votes)
    Default Khan Academy avatar avatar for user
  • winston default style avatar for user Jcim Grant
    Can the Internet Protocol Suite be used to build other websites?
    (1 vote)
    Default Khan Academy avatar avatar for user
    • mr pants pink style avatar for user louiseemily
      You don't use protocols to build websites. You use protocols to use the internet and access websites from a browser. IE - retrieve the website from the correct server - protocols allow you to safely and reliable do this. To build a website you need to create a file - usually the file includes HTML, CSS and JavaScript depending on what you are building.
      (5 votes)
  • orange juice squid orange style avatar for user ogulcanturkaybola6690
    ᠴᠠᠨ ᠶᠥᠦ ᠫᠷᠥᠳᠦᠴᠡ ᠮᠥᠷᠡ ᠤ᠋ᠳᠡᠥᠰ ᠠᠪᠥᠦᠲ ᠴᠥᠮᠫᠦᠲᠡᠷ ᠰᠴ᠋ᠡᠨᠴᠡ ᠫᠯᠡᠠᠰᠡ᠎ ᠳᠥᠨᠲ ᠦᠨᠳᠡᠷᠰᠲᠠᠨᠳ ᠸᠡᠯᠯ ᠹᠷᠥᠮ ᠡᠨᠭᠯ᠋ᠰᠬ ᠠᠷᠲ᠋ᠴᠯᠡᠰ
    (3 votes)
    Default Khan Academy avatar avatar for user
  • piceratops tree style avatar for user Gavenavičius
    I think DNS is when old computer calling router with strange old noise.
    (2 votes)
    Default Khan Academy avatar avatar for user