Operations 10 min read

How to Test Local Network Speed on Linux, Windows, and macOS with Free Tools

This guide explains how to measure local network performance on Linux, Windows, and macOS using free command‑line utilities such as speedtest‑cli and iperf, as well as graphical tools like Speedtest, and provides advanced techniques with Wireshark, ping, and network‑optimization tips.

Liangxu Linux
Liangxu Linux
Liangxu Linux
How to Test Local Network Speed on Linux, Windows, and macOS with Free Tools

Testing Local Network Speed on Linux

Speedtest‑cli ( https://github.com/sivel/speedtest-cli) is a simple command‑line client for measuring download and upload bandwidth. sudo apt-get install speedtest-cli After installation, run: speedtest-cli The tool connects to the nearest Speedtest server and reports download, upload, and latency.

iperf ( https://iperf.fr) provides more detailed performance metrics. sudo apt-get install iperf Start the server on a machine: iperf -s Run the client from another host (replace <server‑IP> with the server address): iperf -c <server‑IP> iperf reports bandwidth, latency, and packet‑loss statistics for TCP tests.

Testing Local Network Speed on Windows

Using the Speedtest GUI

Visit https://www.speedtest.net in a browser, click the “Go” button, and wait for the test to finish. The result shows download, upload, and latency.

Basic test with PowerShell

PowerShell can perform a simple connectivity test:

Test‑NetConnection -ComputerName example.com -Port 80

This command checks reachability to the target host and reports round‑trip time and basic bandwidth information.

Installing and using iPerf for Windows

Download the Windows iPerf package from https://iperf.fr/iperf-download.php, install it, then start the server: iperf -s On the client machine run: iperf -c <server‑IP> The output mirrors the Linux iPerf results.

Testing Local Network Speed on macOS

Speedtest by Ookla application

Open the Speedtest website ( https://www.speedtest.net/) or download the official app from the Mac App Store, then click “Go” to run the test.

Basic test from Terminal

Download a test file to measure download speed:

curl -o /dev/null http://speedtest.wdc01.softlayer.com/downloads/test10.zip

Replace the URL with any file source to suit your bandwidth.

Installing iPerf via Homebrew

Homebrew ( https://brew.sh) is the macOS package manager. Install it (if not already present) and then iPerf:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
brew install iperf

Start the server: iperf -s Run the client: iperf -c <server‑IP> This provides the same detailed bandwidth and latency data as on Linux.

Advanced Testing Methods and Additional Tools

Analyzing traffic with Wireshark

Wireshark ( https://www.wireshark.org) captures and inspects network packets.

Install Wireshark on your system.

Open the application and select the appropriate network interface.

Start a capture, perform the network activity you want to measure (e.g., file download, video streaming).

Stop the capture and analyze the packet list for throughput, latency, and retransmissions.

Latency testing with Ping

Ping measures round‑trip time to a target host: ping <target‑IP> Lower RTT values indicate better latency; packet‑loss percentages are also reported.

UDP testing with iPerf

For real‑time applications, run iPerf in UDP mode using the -u flag: iperf -u -c <server‑IP> The output includes UDP packet loss and jitter, useful for VoIP or video‑stream performance assessment.

Network Optimization

Adjusting MTU size

Changing the Maximum Transmission Unit can improve throughput.

# View current MTU
ip link show

# Set MTU to 1500 (example)
sudo ip link set dev eth0 mtu 1500

Enabling Jumbo Frames

If your hardware supports it, enable Jumbo frames to allow larger packets, reducing overhead.

Using caching and CDN

Local caching : Deploy a proxy such as Squid to cache frequently accessed resources.

Content Delivery Networks : Offload static assets to services like Cloudflare, Akamai, or Amazon CloudFront.

Updating drivers and firmware

Keep network‑adapter drivers and router/switch firmware up to date to avoid performance regressions.

Monitoring network performance

Deploy monitoring stacks such as Prometheus ( https://prometheus.io) together with Grafana ( https://grafana.com) to collect and visualize bandwidth, latency, and error metrics in real time.

LinuxWindowsWiresharkmacOSnetwork testingiperfspeedtest-cli
Liangxu Linux
Written by

Liangxu Linux

Liangxu, a self‑taught IT professional now working as a Linux development engineer at a Fortune 500 multinational, shares extensive Linux knowledge—fundamentals, applications, tools, plus Git, databases, Raspberry Pi, etc. (Reply “Linux” to receive essential resources.)

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.