speedtest-cli

Multi-stream internet speed test with bufferbloat + watch mode

v1.1.1
Linux

Quick Start

Install

curl -fsSL https://cli.johlem.net/install.sh | bash -s -- speedtest-cli

Uninstall

curl -fsSL https://cli.johlem.net/uninstall.sh | bash -s -- speedtest-cli

NixOS / Nix

nix profile install "tarball+https://cli.johlem.net/releases/cli-johlem-net-latest.tar.gz#speedtest-cli"

Features

Requirements

Runtime

Linux x86_64 (zero runtime deps)

Dependencies

Zero third-party dependencies — Python standard library only.

Network

Outbound HTTPS access to speed.cloudflare.com (primary) and download.thinkbroadband.com (fallback). ISP/geo lookups use ip-api.com and api.ipify.org but are non-fatal if blocked.

Usage

speedtest-cli [OPTIONS]

Run speedtest-cli --help to see every flag.

Flags

FlagPurpose
--download-onlyOnly run the download leg of the test
--upload-onlyOnly run the upload leg of the test
--quickFast single-sample test (less accurate, no warm-up)
--size SIZECustom size for ETA estimation (e.g. 1GB, 500MB, 2.5GB)
--no-colorDisable ANSI colour output
--jsonOutput final results as JSON (suppresses live progress)
--server URLCustom download test URL (must accept ?bytes=N)
--versionPrint the version banner

Examples

Full speed test

$ speedtest-cli

  ╔══════════════════════════════════════════════════════╗
  ║   speedtest-cli  v1.0.0  —  CLI Internet Speed Test  ║
  ╚══════════════════════════════════════════════════════╝

  ── Network Info ────────────────────────────────────────
  External IP: 203.0.113.42  Local: 192.168.1.50
  ISP: Example Telecom — Luxembourg, LU

  ── Ping / Latency ──────────────────────────────────────
  Ping: 14.2 ms avg  jitter 1.8 ms

  ── Download ────────────────────────────────────────────
  Result: 487.31 Mbps  ✓  Very Good

  ── Upload ──────────────────────────────────────────────
  Result: 92.18 Mbps  ◎  Good

Fast single-sample test

$ speedtest-cli --quick

Estimate transfer time for a custom size

$ speedtest-cli --size 2.5GB
  ...
  ─── Custom Size: 2.5 GB ─────────────────────────────
  Download: 42s
  Upload:   3m 38s

JSON output for scripting

$ speedtest-cli --json
{
  "timestamp":    "2026-05-26T15:42:11",
  "external_ip":  "203.0.113.42",
  "isp":          "Example Telecom",
  "ping_ms":      { "avg": 14.2, "jitter": 1.8 },
  "download_mbps": 487.31,
  "upload_mbps":   92.18
}

Download only, no colour, log-friendly

$ speedtest-cli --download-only --no-color >> speedtest.log

Install Layout

# Standard layout for all cli.johlem.net tools
~/.local/lib/speedtest-cli/                       # Tool source files
~/.local/bin/speedtest-cli                        # Executable wrapper
~/.local/log/cli.johlem.net/speedtest-cli_*.log   # Install/uninstall logs

After install, run speedtest-cli --help (requires ~/.local/bin in your PATH).

Changelog

# Changelog

All notable changes to `speedtest-cli` (Rust). Format: [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).

## [1.1.0] — 2026-06-06

Release notes pending — fill in before announcing.

## [1.0.0] — 2026-06-05

Initial Rust release.

Integrity

Verify your download against these SHA256 checksums:

FileSHA256

This tool is provided as-is with no warranty. Use at your own risk. Always review scripts before running them. Not responsible for any damage or data loss. Intended for authorized network diagnostics, research, and educational purposes only.