Take the 2-minute tour ×

Instead of going to sites like Netspeed etc i want to check my current internet speed in terminal in 11.10, how can i do it?

share|improve this question
There appear to be lots of answers to this question here. –  Raugturi Feb 16 '12 at 14:47
@Raugturi - The link given in your comment works no more. Please consider removing the comment. –  Ninad Nov 18 '13 at 12:38
add comment

6 Answers

up vote 13 down vote accepted

Well I use wget for it. That little tool tells me nicely what speed I have.

To use it just point to a file in internet that is relatively bigger so that you can get a better estimate of it.

For example

typing: wget http://hostve.com/neobuntu/pics/Ubu1.avi would start to download the Ubu1.avi file and show at what speed it is downloading.

enter image description here

Of course there are several recommendations:

  1. Speed test yourself with good servers. In the case of my link the speed is less than 200KB so if you have a higher speed, the server will be the bottleneck for you, not your actual speed.

  2. The highest speed you will see is the maximum speed that your connection and the server's connection can offer. If your connection is 512KB and the place where you are downloading is 400KB, your max connection will be 400KB because it is the max for the server you are downloading from.

  3. You need to do the test at least 5 times to have a reliable speed check or at least do it for a minute or two. This will help you have a more accurate check.

  4. You need to have at least 4 or 5 different testing sources to have a more accurate speed. Never test only from the same site as this can be affected by your distance to it, any problem in the server and the connections to it, etc. Always test from different servers.


This is an alternative to wget. The downside of wget is the lack of parallel connections. To use aria2 we fist need to download it:

   sudo apt-get install aria2

To use it is simple:

enter image description here

In the image, the -x 4 is how many parallel connections we wish to use. The CN parameter in the next line shows how many active parallel connections were permitted to download from that site. In this case CN is 4. But if we tried to have more connections we would get something like this:

enter image description here

We set 8 parallel connections but the site only allowed a maximum of 5 as shown by CN:5. This could be solved by the -j option which tells aria2c the maximum concurrent connections we want (Which by default is 5) but if the server has limited this, -j will not work.

share|improve this answer
wget is not (yet) able to do a segmented download, that is to download a single file using multiple (parallel) connections, so if your ISP is limiting the speed per 1 connection, you won't get accurate results... it would be a more precise test to use some other tool, that can at least use segmented download (like aria2) –  Mladen B. Aug 7 '13 at 9:21
@MladenB. Thanks. Added Aria2 to it. –  Luis Alvarado Aug 7 '13 at 10:10
add comment


The short version is this:

$ chmod +x speedtest-cli
$ ./speedtest-cli
Retrieving speedtest.net configuration...
Retrieving speedtest.net server list...
Testing from Comcast Cable (x.x.x.x)...
Selecting best server based on ping...
Download: 32.29 Mbit/s
Upload: 5.18 Mbit/s
share|improve this answer
Can you summarize the important information from your blog post in your answer? –  Eliah Kagan Mar 19 '13 at 8:36
The blog post is just an explanation about the program and how to install it. The program is a tool for measuring speed just like speedtest.net does, using the same servers (and automatically location the nearest). –  Giovanni P Jul 4 '13 at 0:23
This doesnt seem to work properly. I have BT infinity 50bBit down and 20Mbit up. But the results show up as 0.53Mbit down and 0.2Mbit up. Huh? Incorrect decimal placing? using wget I get 4.27M/s (34Mbit) (some other server though)? –  ppumkin Sep 2 '13 at 21:53
Installing git might be overkill for most Ask Ubuntu readers. You can just download the repo from github.com/sivel/speedtest-cli/archive/master.zip –  brianpeiris Oct 9 '13 at 8:45
As it has already been stated here: Since speedtest-cli is a python application, it is much easier to install by doing: pip install speedtest-cli or: easy_install speedtest-cli Depending on how Python is installed on your system, you may need to be root to do the above. –  CrandellWS Feb 9 at 4:18
show 1 more comment

try this on command line


try this too


got it from above link

share|improve this answer
Could you plz explain what /dev/null stands for? –  nutty about natty Apr 4 '13 at 11:14
It is speacial file which simply the delete data written to it, –  Tachyons Apr 4 '13 at 12:24
add comment

If you can't be bothered to install iperf , you could precede any command that shifts a known amount of data with the time command and do a sum.

iperf is simple and easy to use.

It requires a client and server.

(on the server)

 user@server$ iperf -s

(on the client)

 user@client$ iperf -c server.domain
 Client connecting to, TCP port 5001
 TCP window size: 16.0 KByte (default)
 [  3] local port 52143 connected with port 5001
 [ ID] Interval       Transfer     Bandwidth
 [  3]  0.0-10.0 sec    113 MBytes  94.7 Mbits/sec

More Details

share|improve this answer
+1 iperf is fantastic for validating ethernet and WIFI speeds –  kfmfe04 May 22 '13 at 10:19
add comment


pip install speedtest-cli


easy_install speedtest-cli


share|improve this answer
add comment

Run several instances of wget with timeout command on large files:


timeout 5 wget -q url_1/100MB.zip &
timeout 5 wget -q url_2/file.zip &
timeout 5 wget -q url_3/sample.mov &
timeout 5 wget -q url_4/speech.mp4 &

And then write a script to calculate the total bytes downloaded and divide 5 seconds you will get a bytes/sec figure. Should be quite accurate and you can add more instances to max your bandwidth.

I have yet to test the full script but the single line command "timeout 5 wget url" works, and you get a partially downloaded file as a result (if 5 secs is not enough to complete the download).

share|improve this answer
This would require of some server set up... –  Braiam Sep 20 '13 at 3:06
url_1,2,3,4 can be anything, such as public servers. –  rexis Sep 20 '13 at 3:27
add comment

Your Answer


