# How to Test Your Internet Speed from the Command Line Itself

**URL:** <https://onehack.st/t/how-to-test-your-internet-speed-from-the-command-line-itself/65050>\
**Category:** Tutorials & Methods\
**Tags:** tips-tricks, pc-optimization\
**Created:** [January 5, 2020, 11:41am UTC](https://onehack.st/t/how-to-test-your-internet-speed-from-the-command-line-itself/65050 "2020-01-05T11:41:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![TheJoker](https://onehack.st/user_avatar/onehack.st/thejoker/32/22660_2.png) [@TheJoker](https://onehack.st/u/TheJoker)\
**Post date:** [January 5, 2020, 11:41am UTC](https://onehack.st/t/how-to-test-your-internet-speed-from-the-command-line-itself/65050/1 "2020-01-05T11:41:22Z")

</div>

[https://cdn.dribbble.com/users/495079/screenshots/3074109/speedtest.gif](https://cdn.dribbble.com/users/495079/screenshots/3074109/speedtest.gif)

Ever wanted to perform a quick internet speed test, but avoid a bloated website like [speedtest.net](http://speedtest.net)? If the answer is ‘Yes’, here’s a quick way to measure your internet speed using the command line.

speedtest-cli is a python tool that allows you to test your internet speed, from the command line, using [speedtest.net](http://speedtest.net). This tool allows you to perform a quick speed test, view all available servers sorted by distance, specify a server that you want to use in order to check your internet speeds, perform only a download or upload test or generate a [speedtest.net](http://speedtest.net) share result image URL.

You can use speedtest-cli on both Linux, macOS and Windows.

1. Install on Linux:

- Arch/Manjaro `sudo pacman -S speedtest-cli`
- Debiant/Ubuntu/Pop!\_OS/Linux Mint/etc `sudo apt install speedtest-cli`
- Fedora `sudo dnf install speedtest-cli`
- openSUSE `sudo zypper install speedtest-cli`
- Other distros: if speedtest-cli is not in the repositories, you can install it using PIP. More info [here](https://github.com/sivel/speedtest-cli#installation).

1.1 Install on macOS:

- use Homebrew. Install with `brew install speedtest-cli`

1.2 Install on Windows

- Slightly more complicated but not impossible. Make sure you have python and pip installed and added to your system path. After that it’s just a matter of installing speedtest-cli using pip. See the installation instruction linked in step 1.

1. Once speedtest-cli is installed, check out the options with `speedtest-cli -h`

 ![image](https://onehack.st/uploads/default/original/3X/4/1/41843a928dd3172ba61de74bddc1350e4e010ca7.jpeg)

1. To check your internet speed simply type `speedtest` or `speedtest --simple` for speedtest-cli to output only the ping, download and upload speeds. For other options, see step 2.

 ![image](https://onehack.st/uploads/default/original/3X/b/e/bed8996867fbdea39a2034fc7216694df26f427f.jpeg)
