tobiaswillmann.de

Estimate if your website is already fast enough by using internet bandwidth speed data of YOUR…

2019-07-01

Google Lighthouse’s default throughput is 1.6Mbps down / 750 Kbps up, which is probably slower than the connection of most of your users (in Europe).

Especially the “in seconds”-metrics like First Contentful Paint or First Meaningful Paint can cause reasonable doubt and discussions with stakeholders if you use the default report to argue for another round of implementing pagespeed optimization features.

So if you optimize your website for speed you probably want to know how fast the connection of your users really is and run the test with YOUR real connection speed. At least for “in seconds”-reports it’s probably better to go with a connection speed of 80% of the users.

In Chrome, Opera, Android webview, Chrome for Android and Opera for Android you can test this within the browser.

E.g. open Chrome console and type:

navigator.connection.downlink

to get your own score.

Scores go from 0–10 and are an effective bandwidth estimate in megabits per second. See:

https://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation/downlink

In some rare cases I get higher numbers than 10, but in general it looks like 0–10 is default.

Scale tests with your website’s users

If you want to collect your users downlink and show it in Google Analytics you can use a Custom Javascript in Google Tag Manager and link it as a Custom Dimension

The Script:

function () {
var con = navigator.connection || navigator.mozConnection || navigator.webkitConnetion
return Math.round(Number(con.downlink));
}

In Google Analytics the information appears like this:

How to decide if your website is already fast enough

My idea would be to decide with this data if you needs further speed optimization or if you are currently fine in terms of website speed. Please keep in mind that speed isn’t a like design or other features, which some users might like but others not — There is almost no user who likes slow websites. To optimize speed is something that can’t be a wrong decision.

Anyway. This could be the process:

  1. Define how many users you are fine to “leave out” with bad speed experience: If your site offers emergency information you should aim for +99% connections being fast. With other less relevant content it’s probably for economical reasons fine to be slow for a small percentage of users which have slow connections. In the example you could say I’m fine to leave out 1.5% of the sessions for a proper speed experience because of their slow connection. If you check the data above 1.4% have connections speeds below 1 Mbps.
  2. Test your site with the defined connection speed (e.g. I want to be fast for > 4 Mbps connections): Setup Google Lighthouse, your Browser or whatever speed testing tool using throttling to the slowest connection speed you want to support and run tests. Now you aim for good metrics in e.g. First Contentful Paint, First Meaningful Paint, Speed Index, Time to Interactive. Also possible is to define the test for the majority of uses.
  3. Your site if fine if you make it to good scores with your defined minimum connection speed / majority connection speed.

I tested multiple sites with European users and from my understanding Lighthouse’s default 1.6Mbps are still reasonable as a minimum connection speed in Europe, if you don’t want to leave out the slowest ~2% of sessions.

There are multiple studies about the connection between website speed and conversions:

https://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation/downlink

More:

https://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation/downlinkhttps://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation/downlink

© 2020 Tobias Willmann