Performing an internet speed test from your Raspberry Pi is a good way to confirm that you are getting the expected download and upload speeds to your device. If you suspect that websites or other external connections are loading slower than they should be, performing a speed test is the first troubleshooting step to take, and allows us to see if our suspicions are correct. After the speed test, we can pinpoint the source of slow downs as either the connection to a router or other local device, or perhaps the ISP itself is the problem.
In this tutorial, you will learn how to perform an internet speed test on any Raspberry Pi model, whether you are using an ethernet or Wi-Fi connection. This will include a GUI method as well as a command line option, in case, for example, you only have an SSH connection to your Raspberry Pi.
In this tutorial you will learn:
- How to download
speedtest
command line tool - How to perform an internet speed test from command line
- How to perform an internet speed test from GUI

Category | Requirements, Conventions or Software Version Used |
---|---|
System | Raspberry Pi |
Software | curl |
Other | Privileged access to your Linux system as root or via the sudo command. |
Conventions |
# – requires given linux commands to be executed with root privileges either directly as a root user or by use of sudo command$ – requires given linux commands to be executed as a regular non-privileged user |
Perform Internet speed test on Raspberry Pi step by step instructions
For those with command line only access, or in case you just prefer using the command line instead of GUI, follow the steps below to perform an internet speed test.
There are many websites online that allow you to test the speed of your internet connection. Perhaps the most popular one is SpeedTest.net. This is the one we will be using to perform our speed test, as they have many server mirrors and support both a command line and GUI functionality for testing. You can use some other site if you choose, or simply attempt to download a large file (like a Linux ISO file download) and measure your speed in a more manual way.
- Let’s start by opening a command line terminal and updating the system’s cache of package information. Then, install the curl command on your system in case you do not already have it.
$ sudo apt update $ sudo apt install curl
- Next, download the Bash script provided on the SpeedTest.net download page. This will add a new repository to our system’s package manager, allowing us to easily install the speed test tool.
$ curl -s https://packagecloud.io/install/repositories/ookla/speedtest-cli/script.deb.sh | sudo bash
- Now we can install the
speedtest
tool viaapt
package manager:$ sudo apt install speedtest
- To get started with performing the speed test, we will use the
speedtest-cli
command. Use the command with no further options and a speed test will be performed:$ speedtest
Performing a speed test on Raspberry Pi via the command line
- To see your speed in megabytes instead of the default megabits, you can append the
-u MB/s
option to your command, like this:$ speedtest -u MB/s
Showing our speed test results in megabytes instead of megabits - If you need to share your speed test results, such as with an internet service provider to prove to them that you are not getting the speeds you are paying for, then you can use the link from your speed test output which should be in your terminal:
The command generates a nifty screenshot that makes it a breeze to share out speed test results with someone
Internet Speed Test – GUI Method
The GUI method works pretty much the same, except the test is performed in your browser instead of the command line terminal. Head over to SpeedTest.net and click on the big button that says “GO.” The nearest server will automatically be selected for you, and then a ping, download, and upload test will be performed. The results will show on your screen when the test is completed.

Closing Thoughts
In this tutorial, we saw how to perform an internet speed test on a Raspberry Pi system. This can be done from either command line or GUI, and the test itself is carried out with SpeedTest.net. Note that there are other sites available for speed tests, including Google, but the results should be about the same between all of them. Performing such a test helps us verify whether we are getting the expected download and upload speeds. If not, check your local network configuration or contact the internet service provider for further troubleshooting.