Bandwidth
- In Turkish
- Bant Genişliği
In short
Bandwidth is the maximum amount of data a network connection can carry per second, usually measured in megabits or gigabits per second (Mbps or Gbps).
What is bandwidth?
Bandwidth is the capacity of a network connection: the maximum amount of data it can transfer in a given amount of time. It is usually measured in bits per second, such as 100 megabits per second (Mbps) or 1 gigabit per second (Gbps). Higher bandwidth means large files, high-resolution video, and many simultaneous users can be handled without slowing down.
Bandwidth is a theoretical maximum, while throughput is the amount of data actually transferred in practice. Throughput is often lower because of network congestion, packet loss, protocol overhead, and the limits of the devices on either end. A transfer is also limited by its slowest link, so a fast home connection won't help if the server you download from is congested.
A water pipe is a helpful analogy: bandwidth is the width of the pipe, which sets how much water can flow through it per second. In software, bandwidth matters when streaming video, transferring backups, serving images to many users, and estimating hosting costs, since cloud providers often bill for outgoing data transfer. Compressing responses, resizing images, and caching all reduce the bandwidth an app uses.
Bandwidth is commonly confused with latency. Bandwidth is how much data can flow at once, while latency is how long each piece of data takes to arrive. Another frequent mix-up is bits versus bytes: network speeds are quoted in megabits (Mb), file sizes usually in megabytes (MB), and one byte equals eight bits, so a 100 Mbps link downloads at most about 12.5 MB per second.
Key takeaways
- Bandwidth is the maximum data transfer capacity of a connection.
- It is measured in bits per second, such as Mbps or Gbps.
- Throughput is the amount actually achieved, and it is often lower than bandwidth.
- Bandwidth is capacity; latency is delay. They are separate measurements.
- Divide megabits by eight to get megabytes: 100 Mbps is about 12.5 MB/s.
Example
// Estimate how long a download takes at a given bandwidth
function downloadSeconds(fileSizeMB, bandwidthMbps) {
const fileSizeMegabits = fileSizeMB * 8; // 1 byte = 8 bits
return fileSizeMegabits / bandwidthMbps;
}
// A 500 MB file over a 100 Mbps connection
console.log(downloadSeconds(500, 100)); // 40 seconds (best case)
// The same file over a 20 Mbps connection
console.log(downloadSeconds(500, 20)); // 200 secondsReaders ask
What is the difference between bandwidth and speed?
People often use them interchangeably, but bandwidth is the maximum capacity of a connection, while the speed you actually see is throughput. Throughput can be lower because of congestion, distance, and other traffic on the network.
What is the difference between Mbps and MB/s?
Mbps means megabits per second and is used for network speeds, while MB/s means megabytes per second and is used for file transfers. Since one byte is eight bits, divide Mbps by eight to get MB/s.
How much bandwidth do I need?
It depends on usage. Browsing and email need very little, a single HD video stream typically needs around 5 Mbps, and 4K streaming usually needs about 15 to 25 Mbps, multiplied by the number of people using the connection at the same time.
See also
- LatencyNetworking, p. 14Latency is the delay between sending a request and the start of a response, usually measured in milliseconds, and it shapes how responsive an app feels.
- CDNDevOps & Cloud, p. 7A CDN is a network of servers spread around the world that stores copies of website content and delivers it to each user from the nearest location.
- PacketNetworking, p. 20A packet is a small, formatted unit of data sent across a network, made of a header with addressing information and a payload that carries the actual data.
- CacheBackend & APIs, p. 8A cache is a fast, temporary storage layer that keeps copies of frequently used data so later requests can be served quickly without repeating slow work.
- Load BalancerDevOps & Cloud, p. 34A load balancer is a server or service that spreads incoming traffic across several backend servers so no single one is overloaded and the app stays available.
- ThroughputNetworking, p. 32Throughput is the amount of data or work a system actually handles per unit of time, like megabits per second on a network or requests per second on a server.
Spotted a mistake or something missing on this page?Suggest an edit