Speedtest-cli error

When I run speedtest-cli, I get this.

Cannot retrieve speedtest configuration
ERROR: HTTP Error 403: Forbidden
1 Like

The problem cleared up. The server was down temporarily.

Hi, @fixit7 .

I've never ran speedtest-cli but, after a web search, I've found the following Reddit post (in the subreddit "r/Linux4noobs") that was posted 23 days ago:

In that Reddit post, the original poster ("u/CryPTuuNe") wrote the following:

"(...) I just setup Ubuntu on my new PC. For testing purposes I installed the speedtest-cli and with the command Speedtest everything worked fine. I don't know what I did then, but now I am getting an http error 403 forbidden. But when doing speedtest --secure everything works fine again. (...)"

According to the "speedtest-cli" manpage - Ubuntu Manpage: speedtest-cli - Command line interface for testing internet bandwidth using speedtest.net - the "--secure" switch has the following meaning:

--secure
Use HTTPS instead of HTTP when communicating with speedtest.net operated servers

I hope this helps.

5 Likes

Thanks ricmarques. I will use --secure from now on.

2 Likes

Thanks for finding this info. Now using --secure :slight_smile:

1 Like

Hi, you can actually put speedtest.Speedtest(secure=1) like this,
hope it help, you guys help me ; )

1 Like

Hi, Ricmarques,
Thanks for your info.
With --secure, it works!

1 Like

Thanks, Ricmarques, but my question is why we need add "--secure"?
I didn't do anything, I just reinstalled my PC, and then speedtest-cli can't work. And I must added "--secure" now, it's so wierd! This problem wastes my half day time. Why without "--secure" option, my original environment could work? The root cause is on the different version of "speedtest-cli"? I suspect so.

1 Like

Welcome @zhongzhong to our community!

1 Like