December 5, 2026

Bandwidth vs Latency vs Throughput: What iperf3 Shows When the Same Link Gets Farther Away

Two network switches joined by a long coiled Ethernet cable

A 100-megabit link carried 96.5 megabits per second in a test with a 64 KB TCP window. The same link, with nothing changed except 50 milliseconds of delay added in each direction, carried 5.6. The pipe was just as wide. It had only gotten longer, and the sender spent most of its time waiting for permission to send more. Bandwidth, latency and throughput get used as if they were one number, usually “speed,” but the tests below show three different quantities that limit each other in ways a speed test alone won’t reveal. Every figure here comes from iperf3 runs in a lab built from two Linux network namespaces, with the link speed capped by the kernel’s traffic shaper and delay added by a small packet-forwarding program.

Video: Neso Academy on YouTube

Three words, three measurements

Bandwidth is the width of the pipe

Bandwidth is the most a link can carry, in bits per second. A “100 Mbps” plan or a gigabit Ethernet port describes capacity, the ceiling, not what any particular transfer achieves.

Latency is the length of the pipe

Latency is how long a bit takes to get from one end to the other. Ping reports round-trip time (RTT): out and back. Distance, routing and queues all add to it, and no amount of extra bandwidth removes it.

Throughput is what actually arrives

Throughput is the data delivered per second for a real transfer. It can never exceed bandwidth, and it often falls well short, because protocols such as TCP are limited by how much data they’re allowed to have in flight while waiting for acknowledgments.

Bits and bytes

Network figures use bits, while download dialogs usually show bytes. A 100 Mbit/s link moves at most 12.5 megabytes per second before any overhead.

Water drop on bucket

The lab and the tool

iperf3 basics

The iperf3 manual describes a client-server tool: one machine runs iperf3 -s and listens on TCP port 5201, the other runs iperf3 -c <host>. By default “the client is the sender and the server is the receiver”; -R reverses the direction. A test lasts 10 seconds unless -t sets otherwise.

The setup

Two Linux network namespaces stood in for two machines. Their link was capped at 100 Mbit/s with the tbf (token bucket filter) queueing discipline in each direction, and a short Python program forwarded every packet between them after a configurable delay. Setting 0, 5, 25 and 50 ms in each direction gave these round-trip times from ping:

One-way delay Measured RTT (avg)
0 ms 0.22 ms
5 ms 10.7 ms
25 ms 50.7 ms
50 ms 100.6 ms

Roughly a LAN, a nearby city, a cross-country connection and an intercontinental one.

The commands

iperf3 -s                         # on the receiving side
iperf3 -c 10.9.1.2 -t 8           # TCP, default settings
iperf3 -c 10.9.1.2 -t 8 -w 64K    # TCP, socket buffer set to 64 KB

What latency does to TCP

The results

RTT Default TCP -w 64K
0.22 ms 96.4 Mbit/s 96.5 Mbit/s
10.7 ms 96.0 Mbit/s 59.0 Mbit/s
50.7 ms 91.4 Mbit/s 11.3 Mbit/s
100.6 ms 88.5 Mbit/s 5.6 Mbit/s

With default settings, Linux tunes its buffers automatically and the throughput stays near the 100 Mbit/s cap, slipping only a little as RTT grows. Pin the window to 64 KB, and throughput collapses as latency rises, by a factor of about 17 between the first row and the last.

Why the window decides

TCP can only send as much unacknowledged data as the receiver’s window allows, then it waits for acknowledgments to come back. RFC 6349, the IETF’s framework for TCP throughput testing, puts it in one formula: “TCP Throughput = TCP RWND X 8 / RTT,” where RWND is the receive window in bytes. A window of 65,536 bytes over a 100.6 ms round trip allows about 5.2 Mbit/s, close to the measured 5.6.

Why the measurement ran a little high

The measured figures sit slightly above the formula at every delay. The Linux socket(7) manual explains part of it: when a buffer size is set, “the kernel doubles this value (to allow space for bookkeeping overhead).” The usable window ends up somewhat larger than the 64 KB requested, though not twice as large.

White and black modem router with four lights

The bandwidth-delay product

How much data is in the pipe

RFC 6349 defines the bandwidth-delay product (BDP) as “the product of a data link’s capacity (in bits per second) and its end-to-end delay (in seconds),” and gives the minimum window needed to fill a link as BDP divided by 8, in bytes. For this lab:

RTT BDP at 100 Mbit/s Window needed
10.7 ms 1.07 Mbit about 134 KB
50.7 ms 5.07 Mbit about 634 KB
100.6 ms 10.06 Mbit about 1.26 MB

At 100 ms, a 64 KB window covers about one-twentieth of what’s needed, matching the collapse in the table above.

Parallel streams as a workaround

Running four TCP streams at once with -P 4, each still limited to a 64 KB window, raised throughput at 100 ms RTT from 5.6 to 22.3 Mbit/s, about four times as much. That’s why download managers and some backup tools open several connections: each one brings its own window. It is a patch for a window that’s too small, not a fix for the latency itself.

Where small windows still show up

Modern operating systems scale windows automatically, as the default column shows. Small windows still appear in older software, in applications that set a fixed buffer size, on some VPN and tunnel setups, and on devices with little memory, which is why a fast connection to a distant server can feel slow while a nearby one is fine.

Latency under load

Queues add delay

A link carrying a full-speed transfer has a queue in front of it, and every packet waiting in that queue adds time. With 0 ms of added delay, the idle round trip measured 0.22 ms. During a 10-second iperf3 transfer at full speed, ping measured an average of 5.1 ms with a maximum of 8.4 ms, more than 20 times the idle figure, on the same cable and the same hardware.

What that looks like at home

The effect is often called bufferbloat when queues are large. A household with one large upload running and a video call starting at the same moment experiences it as the call stuttering while the bandwidth number on the router looks fine. Testing latency while the line is busy, not only when it’s idle, reveals it.

UDP has no window

UDP doesn’t wait for acknowledgments, so iperf3’s UDP mode (-u) tests differently: the client sends at a target rate set with -b, which defaults to 1 Mbit/s according to the manual. At 50 Mbit/s in the lab, UDP delivered all 25,895 packets with a jitter (variation in packet arrival time) of 0.25 ms. Set above the link’s capacity, at 150 Mbit/s, it topped out at 98.2 Mbit/s. In this lab the bottleneck queue sat on the sending machine itself, so the kernel slowed the sender instead of dropping packets. On a real network, where the bottleneck is usually a router somewhere along the path, excess UDP traffic is dropped, and iperf3 reports it as loss.

Blue and pink fiber optic decor

Running a useful test at home

Test against something close and something far

A speed test to a nearby server measures bandwidth. Running iperf3 against a machine on the same LAN, then against a server in another region, separates a slow link from a long one. If the LAN number is fine and the distant one isn’t, latency and windowing are suspects, not the cable.

Measure latency during the transfer

The bufferbloat check takes two terminals. One starts a long transfer with iperf3 -c <host> -t 30; the other runs ping <host> at the same time. Comparing the ping figures from before and during the transfer shows how much delay the queues add when the line is busy, which is the number a video call actually feels.

Check both directions

Adding -R runs the test with the server sending. Home connections are often asymmetric, and a problem that only shows up on uploads hides from a download-only test.

Read the retransmits

iperf3’s TCP summary includes a retransmit count. Every run in this lab reported zero, which is what a clean path looks like. A steady stream of retransmits points to loss somewhere, and loss cuts TCP throughput far more sharply than latency alone.

The number that matters depends on the job

Large file transfers care about throughput. Games, calls and remote desktops care about latency and how much it varies. A connection can score well on one and badly on the other, and the label on the plan only describes the width of the pipe.

Sources

  • iperf3 documentation, Invoking iperf3, ESnet: https://software.es.net/iperf/invoking.html
  • RFC 6349, Framework for TCP Throughput Testing (August 2011), RFC Editor: https://www.rfc-editor.org/rfc/rfc6349
  • socket(7), Linux manual page: https://man7.org/linux/man-pages/man7/socket.7.html

920 Posts

Peter Kalafatis writes and edits X9M8. He holds a bachelor's degree from LIU Post and a master's in Media Studies from The New School, with academic work in the philosophy of science, human behavior, AI, and memetics.

View All Posts

Leave a Reply

Your email address will not be published. Required fields are marked *