Skip to content
speedtest.doctor
Developers

How to Embed a Speed Test on Your Website in 2026

speedtest.doctor Team 8 min read

Sending visitors to an external speed test was never ideal — you lose the session, the branding, and the chance to help before they bounce. In 2026, the better pattern is to embed a speed test directly on your support page, onboarding flow or ISP portal. A modern website widget runs diagnostics in-place, reports real numbers, and keeps users inside your experience.

Why embed instead of link out?

ISPs, MSPs, SaaS platforms and technical blogs all hit the same friction: a customer says "my internet is slow" and you send them elsewhere to prove it. Embedded network diagnostics flip that workflow. The test runs on your domain, results stay in context, and you can pair the widget with your own troubleshooting content or ticket form.

For developers, a network diagnostics embed also means SEO stays on your site, Core Web Vitals are under your control, and you can theme the UI to match your design system — not someone else's ad-heavy test page.

Choose your layout: banner vs square

speedtest.doctor ships two layouts on /widgets:

Banner

Wide, horizontal chrome. Best for hero sections, dedicated "Test your connection" pages and full-width support articles.

Square

Compact card. Fits sidebars, footers, knowledge-base aside panels and mobile-first layouts.

Both layouts support data-theme="dark" or light, plus a custom accent colour so the widget feels native to your brand.

Quick start: embed code in two lines

The speed test widget does not require an API key. Drop this into any HTML page, CMS block or static site template:

html
<!-- Speed test widget — no API key required -->
<div id="std-widget" data-service="speedtest" data-layout="banner" data-theme="dark"></div>
<script src="https://cdn.speedtest.doctor/widget.js" async></script>

The script loads from cdn.speedtest.doctor and mounts into the container div. Change data-layout to square for the compact variant. Every widget on /widgets has a live preview and a copy-ready snippet.

API keys, credits and the free tier

The speed test embed is free with no key. Diagnostic tool widgets — SSL check, ping, DNS benchmark, traceroute and more — call the Measurement API and need an API key. New accounts at app.speedtest.doctor include 100 API credits on the free tier: enough to prototype embeds, run internal demos, or support a low-traffic support portal.

Create keys, pick services and generate embed codes in the widget dashboard. Paid plans scale call volume for production sites. Full request and response shapes are documented at /docs.

Beyond speed: diagnostic widget catalog

A speed test answers "how fast?" — but support tickets rarely stop there. The same embed platform offers widgets for SSL/TLS checks, ping and packet loss, DNS benchmarks, HTTP headers, port scans, WHOIS and full connection diagnosis. Browse the gallery on /widgets and the tool index at /tools.

Mix a banner speed test on your homepage with a square SSL widget on your status page. Each embed shares the same measurement stack as the main speedtest.doctor site — self-hosted at api.speedtest.doctor, not inflated by third-party CDNs.

Implementation checklist for 2026

  1. 01Pick layout (banner or square) and theme on /widgets — preview live before copying code.
  2. 02Paste the embed snippet into your CMS, React layout or static template.
  3. 03For tool widgets, sign up and create an API key in the dashboard.
  4. 04Test on mobile — square layout often works better in narrow viewports.
  5. 05Link adjacent troubleshooting content so users know what to do with the results.

CMS and framework integration tips

WordPress, Webflow, Ghost and static generators all accept raw HTML embeds. Paste the snippet into a Custom HTML block, embed component or partial template. In React or Vue SPAs, mount the container div in your component and load the script in useEffect or on route enter so the widget initialises once per navigation.

For Content Security Policy headers, allow cdn.speedtest.doctor in script-src and connect-src so the widget can reach api.speedtest.doctor during tests. Details and endpoint list are in /docs.

Measuring ROI on embedded diagnostics

Teams that embed diagnostics typically see fewer "send us a speed test screenshot" tickets because customers self-serve before opening chat. Pair the widget with a short guide — link to our slow connection checklist or your own runbook — so users know what to do when ping is high or upload is asymmetric. The widget captures the data; your content closes the loop.

Accessibility and mobile layout

Embedded tests should work on phones, not just desktop support portals. The square layout fits narrow viewports; banner layout scales down but needs at least 320 px container width. Test with touch input — the Start button must be large enough to tap without zooming. speedtest.doctor widgets use semantic markup and sufficient colour contrast in both themes so they pass basic accessibility checks out of the box.

Embed your first widget today

Preview every layout live, copy the snippet, and manage keys from your dashboard.

Frequently asked questions

Is embedding a speed test free?
Yes. The speed test widget itself requires no API key. Sign up at app.speedtest.doctor for a free account with 100 API credits — enough to power SSL, ping, DNS and other diagnostic widgets during evaluation. Paid tiers scale for production traffic.
What is the difference between banner and square widget layouts?
Banner layout spans the full width of its container — ideal for hero sections, support pages and ISP portals. Square layout fits sidebars, footers and narrow columns. Both run the same measurement engine; only the chrome changes.
Will an embedded speed test slow down my website?
The widget script loads asynchronously and runs tests only when the user clicks Start. It does not block your page render. For best performance, place the embed below the fold or lazy-load the script on pages where diagnostics are secondary.
Can I white-label the embedded speed test?
Yes. Choose light or dark theme and set a custom accent colour to match your brand. The speed test widget includes a dofollow Powered by speedtest.doctor link for attribution; tool widgets use your API key and inherit your dashboard settings.
How do I embed network diagnostics beyond a speed test?
Visit /widgets to preview ping, SSL, DNS, traceroute and other tool widgets live. Each diagnostic widget needs an API key from your dashboard. Full endpoint reference is in /docs.