Tutorials · Troubleshooting
How to Test Network Speed Between Two Points With iperf3
Internet speed tests do not tell you how fast your LAN, Wi-Fi or site-to-site link really is. iperf3 measures throughput, loss and jitter between two machines you control.
Before you start
- Two computers or servers, one at each end of the link
- iperf3 on both (apt install iperf3, brew install iperf3, or the Windows build)
- TCP/UDP port 5201 allowed between them
Step by step
Start the server
Run iperf3 in server mode on the machine at the far end.
iperf3 -sRun a TCP test
From the other machine, test for 30 seconds. The result is the throughput from client to server.
iperf3 -c 10.1.20.15 -t 30Test the other direction
-R reverses the test so the server sends to you. Many problems only show in one direction.
iperf3 -c 10.1.20.15 -t 30 -RUse parallel streams for fast links
One TCP stream may not fill a 10G link or a long-distance WAN. Use 4–8 streams.
iperf3 -c 10.1.20.15 -t 30 -P 8Measure loss and jitter with UDP
For voice and video, test UDP at the expected rate and read loss % and jitter. Voice needs under 1% loss and under 30 ms jitter.
iperf3 -c 10.1.20.15 -u -b 50M -t 30Compare with what you expect
Gigabit wired: about 940 Mbit/s. Wi-Fi 6 on 80 MHz close to the AP: often 500–900 Mbit/s. Site-to-site VPN: below the ISP contract because of encryption overhead. Much lower results point to a bottleneck to investigate.
Stop the server
Do not leave iperf3 listening on production servers. Stop it with Ctrl+C when finished.
Commands are generic, industry-standard examples. Exact syntax and menu names vary by model and firmware; check your device's manual on the Documentation page.
Pro tips
- Test from wired to wired first, then add Wi-Fi: this separates LAN problems from wireless problems.
- Laptop power saving and old USB adapters limit results. Use a good wired NIC for baseline tests.
- Run tests at quiet times so you do not disturb users.
FAQ
Frequently asked questions
Why is my result lower than the link speed?
Protocol overhead (about 6% on Ethernet), CPU limits, Wi-Fi conditions, VPN encryption or a congested link. Test with -P and in both directions to narrow it down.
Is iperf3 safe to run on the Internet?
Only between hosts you own. Public iperf servers exist, but results depend on their load.
Keep learning
Related guides
Find why the network is slow
Read more →Plan Wi-Fi channels
Read more →Site-to-site IPsec VPN
Read more →How to Troubleshoot Network Problems With Ping, Traceroute and MTR
Find where a connection breaks or slows down in minutes. Use ping for reachability and loss, traceroute for the path, and MTR to see loss and latency on every hop at once.
Read more →How to Capture and Read Network Traffic With Wireshark and tcpdump
When logs are not enough, look at the packets. Capture traffic with tcpdump or Wireshark, filter it down to the problem, and spot retransmissions, DNS failures, DHCP issues and TLS errors.
Read more →How to Troubleshoot DNS Problems With dig and nslookup
'The Internet is down' is often DNS. Learn to check which DNS server a device uses, query records directly, compare answers and clear caches.
Read more →Stuck on a step?
Ask Navijin technical support or an authorised partner for help with your configuration.