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

Transporting bits over wires

The Internet is a network of computers communicating with each other. When humans communicate with each other, we use words and body language. When computers communicate with each other, they use 1s and 0s. That's easy for computers since they already represent all their data in binary.
If you don't remember binary data, now is a great time to review the first unit on digital data representation.

Sending streams of 1s and 0s

When computers need to internally represent the number 5 (101 in binary), they can use three wires to represent the 3 bits: one wire on, one wire off, one wire on.
Diagram of 3 wires. The first has electric pulses going through it and is labeled with the number 1. The second is empty and black and is labeled with the number 0. The third has pulses and is labeled with 1.
If a computer wants to send the number 5 to another computer, they can't use as many wires as they want. In fact, they may only have a single wire to send information over. Instead, they can send the number 5 over three time periods: first sending an on pulse (and waiting), then sending nothing (and waiting), then sending an on pulse.
Diagram of a single wire. The first third of the wire has electric pulses and is labeled 1. The middle third is empty and is labeled 0. The final third has electric pulses and is labeled 1.
As long as the two computers agree on the time period, then they can transfer information to each other, turning binary data into pulses and turning the pulses back to binary data.
Diagram of two computers. A wire connects computer A to computer B, with an arrow towards computer B, and on/off/on pulses. A wire connects computer B to computer A, with an arrow towards computer A, and on/on/off pulses. Computer A's monitor says "Sent: 101, Received: 110". Computer B's monitor says "Received: 101, Sent: 110".

Bit rate

Computer networks can send bits very fast. We measure that speed using the bit rate, the number of bits of data that are sent each second. The earliest Internet connections were just 75 bps (bits per second). These days, connections are more often measured in Mbps (megabits per second).
A megabit is huge: 1 million bits! A 10 Mbps connection transfers data at 10 million bits per second.
That's one bit every 100 nanoseconds (0.0000001 seconds).
Diagram of a wire. Inside the wire are three equal sized blocks of color. The first block is colored yellow and labeled 1. The second block is colored black and labeled 0. The third block is colored yellow and labeled 1. Underneath the wire is a time scale that starts at .0000001 seconds and ends at .0000003 seconds.
We also measure bit rate in smaller units like kilobits (1 thousand bits) or much bigger units like gigabits (1 billion bits) and even petabits (1 quadrillion bits).
unit# of bits
kilobit10001 thousand
megabit100021 million
gigabit100031 billion
terabit100041 trillion
petabit100051 quadrillion
Check your understanding
When I was growing up, our Internet connection was 56 Kbps (kilobits per second). How many bits per second could that transfer?
Choose 1 answer:

Bandwidth

We use the term bandwidth to describe the maximum bit rate of a system. If a network connection has a bandwidth of 100 Mbps, that means it can't transfer more than 100 megabits per second. Fortunately, that's still a lot!
Ever heard the term "broadband Internet"? That refers to a connection with a minimum bandwidth of 256 Kbps. That's enough bandwidth for basic Internet use like checking emails and reading websites, but not quite enough for watching online videos. As of 2016, only 40% of people in developing nations have access to even broadband Internet.

Latency

Another way to measure the speed of a computer network is latency. You might guess what that means from the word itself: latency measures how late the bits arrive. To put it in more formal terms: latency is the time between the sending of a data message and the receiving of that message, measured in milliseconds.
We typically measure the "round-trip" latency of a request. Let's walk through a real example to see what that means.
Illustration of round-trip latency. A laptop is shown with "ping www.google.com" on the screen. An arrow goes from the laptop to a server, and is labeled as "30 ms". Another arrow goes back from the server to the laptop, and is labeled as "40 ms."
My computer sends a message to the Google server. 30 milliseconds later, Google receives the message. 40 milliseconds later, my computer gets an acknowledgement from Google that it received the message.
That's a total round-trip latency of 70ms. The latency depends on a number of physical factors: the type of connection from my computer to Google, the distance from my computer to the Google servers, and the congestion in the network (which may mean my request has to wait in line).
There's a major limiting factor to latency: the speed of light. Nothing can move faster than light, not even our very important Internet requests. The speed of light is 1 foot per nanosecond, which means a trip length of at least 30 ms from Los Angeles to Tokyo. We can't do much about the speed of light, but we can decrease latency by reducing congestion and improving our physical connections.

Physical connections: Ethernet, Fiber, and WiFi

The Internet is a series of computers connected to each other. But what does that physical connection look like? It depends on the needs of the connection and the size of the network.
Ethernet cables are a common type of connection made up of twisted copper wires. Electricity pulses through them at a bit rate up to 400 Gbps. Ethernet cables are used in networks as small as LANs (local area networks) like a company's office or as large as WANs (wide area networks) like an entire country.
If you're in a computer lab or next to a modem, you can probably find an Ethernet cable just like this one:
Photo of the end of an ethernet cable.
 
Fiber optic cables send pulses of light instead of electricity, and they can send terabits per second. They connect computers across the oceans, so that we can quickly send data across the world. As they become less expensive, they're becoming increasingly common in city-wide networks as well.
Photo of a fiber optic cable, with light coming out of both ends.
Image source: Hustvedt, Wikipedia
Wireless connections don't involve any wiring at all—at least at first. A wireless card in the computer turns binary data into radio waves and transmits them through the air. Those radio waves can't travel very far: 75-100 feet in a place like an office building that's filled with all sorts of obstacles, or up to 1000 feet in a wide open field.
The waves are hopefully picked up by a wireless router, also called an access point, which converts them from radio waves back into binary data. Wireless access points are connected to the rest of the network using physical wiring, like ethernet or fiber cables.
Photo of a wireless router with ethernet and power cables plugged into it.
Image source: Ahunt, Wikipedia

At any given time, our Internet connection might be using a combination of those technologies. Maybe we're using WiFi to connect to our home router, our home router is using ethernet copper cables to connect to the metropolitan network, and those cables are hopping over fiber to communicate with overseas data centers.
Each technology has its pros and cons, so we use whatever is best for the job.
TypeSendsDistanceBandwidthIssues
WirelessRadio100 ft1.3 GbpsSlower in reality
Ethernet copper cablesElectricity330 ft1 GbpsCan lose data
Fiber optical cableLight50 miles26 TbpsExpensive
Engineers are always working to improve existing technology and invent new technology, so we may be using new kinds of connections in the future that are faster, more reliable, and less expensive.

Internet speed

Speed is a combination of bandwidth and latency. Computers split up messages into packets, and they can't send another message until the first packet is received. Even if a computer is on a connection with high bandwidth, its speed of sending and receiving messages will still be limited by the latency of the connection.
You can measure the current speed of a network using an Internet speed test, a website that downloads and uploads data while tracking how quickly the data is transferred.
Here are the results from an Internet speed test from my home laptop:
Screenshot from an Internet speed test. It says "Ping: 18 ms", "Download: 39.09 Mbps", and "Upload: 5.85 Mbps".
The latency (also called the ping rate) was just 18ms. That's fast enough for most multi-player online games.
The download bit rate is 39 Mbps and the upload bit rate is 5.85 Mbps, significantly less. Actually, that's expected. Internet providers often support a much faster download speed than upload speed, because Internet users spend much more time downloading data (reading articles, watching movies) than uploading data (writing blog posts, submitting forms).
🔍 What's the speed of your Internet? What bandwidth does your Internet provider promise? What type of connection are you on? This is a great opportunity to get a deeper understanding of the physical infrastructure you use every day.

Want to join the conversation?