speedtest-cli

Crates.iospeedtest-cli
lib.rsspeedtest-cli
version0.1.0
created_at2026-01-05 17:24:53.137337+00
updated_at2026-01-05 17:24:53.137337+00
descriptionA fast and simple CLI tool to test internet connection speed with real-time progress indicators
homepagehttps://github.com/VillegasMich/speedtest-cli
repositoryhttps://github.com/VillegasMich/speedtest-cli
max_upload_size
id2024277
size65,611
Manuel Villegas Michel (VillegasMich)

documentation

https://docs.rs/speedtest-cli

README

speedtest-cli

A fast and simple command-line tool to test your internet connection speed, written in Rust.

Features

  • Download Speed Test: Measure your download speed
  • Upload Speed Test: Measure your upload speed
  • Full Speed Test: Run both download and upload tests
  • Multiple Units: Display results in bps, Kbps, Mbps, or Gbps
  • Verbose Logging: Debug mode for detailed test information
  • Colorful Output: Easy-to-read colored terminal output

Installation

From crates.io (once published)

cargo install speedtest-cli

From source

Clone and build:

git clone https://github.com/yourusername/speedtest-cli.git
cd speedtest-cli
cargo build --release

The binary will be available at target/release/speedtest-cli

Install directly to PATH

Build and install in one step:

git clone https://github.com/yourusername/speedtest-cli.git
cd speedtest-cli
cargo install --path .

This will compile the binary and install it to ~/.cargo/bin/ (which should be in your PATH). After installation, you can run speedtest-cli from anywhere.

To uninstall:

cargo uninstall speedtest-cli

Usage

Basic Commands

Run a full speed test (download + upload):

speedtest-cli start

Test download speed only:

speedtest-cli download

Test upload speed only:

speedtest-cli upload

Options

Unit Selection

Use the --unit or -u flag to specify the output unit:

speedtest-cli start --unit mbps    # Megabits per second (default)
speedtest-cli download -u kbps     # Kilobits per second
speedtest-cli upload --unit gbps   # Gigabits per second
speedtest-cli start -u bps         # Bits per second

Available units:

  • bps - bits per second
  • kbps - kilobits per second
  • mbps - megabits per second (default)
  • gbps - gigabits per second

Verbose Mode

Enable detailed logging with the --verbose or -v flag:

speedtest-cli start --verbose
speedtest-cli download -v

Examples

# Quick download test with default settings
speedtest-cli download

# Full test showing results in Kbps
speedtest-cli start -u kbps

# Upload test with verbose logging
speedtest-cli upload -v

# Download test in Gbps with debug info
speedtest-cli download --unit gbps --verbose

Help

Get help for any command:

speedtest-cli --help
speedtest-cli start --help
speedtest-cli download --help
speedtest-cli upload --help

Sample Output

=> Running full speed test (download + upload)...

Speed Test Results
===================
Download Speed: 48.42 Mbps
Upload Speed:   25.08 Mbps

Requirements

  • Rust 1.70 or higher
  • Active internet connection

Dependencies

  • clap - Command-line argument parsing
  • tokio - Async runtime
  • reqwest - HTTP client
  • env_logger & log - Logging
  • colored - Terminal colors
  • thiserror - Error handling
  • futures-util - Async utilities

How It Works

The tool performs speed tests by:

  • Download: Downloading test files from reliable servers and measuring transfer rate
  • Upload: Uploading data to test endpoints and measuring transfer rate

Results are calculated in bytes per second and converted to your chosen unit.

License

MIT

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Roadmap

  • Add server selection options
  • Support for latency/ping tests
  • JSON output format
  • Configuration file support
  • Progress bars for long tests

Made with ❤️ and Rust

Commit count: 0

cargo fmt