@cloudflare/speedtest is a JavaScript module to measure the quality of Internet connection. It’s the measurement engine that powers the Cloudflare speedtest measurement application.

Installation steps are as follows:

Add this package to your package.json by running this in the root of your project’s directory

npm i @cloudflare/speedtest


import SpeedTest from '@cloudflare/speedtest';
new SpeedTest().onFinish = results => console.log(results.getSummary());


Support On Demand!