invisit
Free tools

Analytics script size

How much each analytics script weighs, fetched from the address its own docs give and compressed the same way, so the numbers compare.

.mdllms.txt
Weight

Measured

  1. Plausible1.3 KB1.1 KB2.8 KB
  2. Vercel Web Analytics2.0 KB1.8 KB4.5 KB
  3. Fathom2.1 KB1.8 KB7.0 KB
  4. GoatCounter3.3 KB2.8 KB9.2 KB
  5. OpenPanel3.4 KB3.0 KB9.6 KB
  6. Pirsch3.5 KB3.0 KB11.8 KB
  7. Umami3.9 KB3.5 KB8.6 KB
  8. Simple Analytics4.8 KB4.3 KB9.6 KB
  9. DataFast5.3 KB4.6 KB15.4 KB
  10. Swetrix6.7 KB5.9 KB23.6 KB
  11. invisit9.0 KB8.1 KB21.2 KB
  12. Cloudflare Web Analytics10.3 KB9.3 KB31.9 KB
  13. Rybbit11.8 KB10.6 KB37.4 KB
  14. Matomo22.2 KB19.3 KB68.3 KB
  15. Mixpanel35.6 KB31.2 KB110.3 KB
  16. Yandex Metrica80.9 KB69.9 KB208.6 KB
  17. PostHog119.9 KB100.6 KB372.8 KB
  18. Google Analytics 4 (gtag.js)154.6 KB128.3 KB443.5 KB

Each script fetched from the address its vendor documents and compressed the same way here (gzip level 9, Brotli quality 11), so a CDN’s own settings don’t tilt the numbers. Hover a name for the address; click it for the vendor’s install docs.

How the numbers were measured

Every script was downloaded from the exact address its vendor tells you to paste into your page, with compression turned off, and then compressed here: gzip at level 9 and Brotli at quality 11. A CDN can send the same file a little smaller or larger depending on its settings, so measuring them all the same way is the only fair comparison. A kilobyte here is 1,000 bytes.

The script that measures them is in the invisit repository, and the page shows the day it last ran. If a vendor changes its script, the numbers move on the next run.

What the size does and doesn’t tell you

A smaller file downloads faster, but download is the cheap part. On a phone the cost is mostly parsing and running the code, which happens on the same main thread as your own scripts. A 150 KB analytics script can show up in Interaction to Next Paint on slower devices even when it loads with async.

Size also isn’t the whole bill. Some tools load more once they run: session replay recorders, surveys, heatmap modules, or other tags pulled in by a tag manager. Where a vendor documents those extras, the Markdown copy of this page lists them.

Check your own site

Open your browser’s developer tools, go to the Network panel, filter by JS and reload. The Transferred column is what came over the wire, Size is what the browser had to parse. Do it once with a throttled CPU and a mobile profile and you’ll see which of your scripts actually cost something.

invisit itself is on the list, measured the same way as everyone else. If size is your main concern, some tools here are lighter than ours, and that’s fine to choose.

Common questions

Which analytics script is the smallest?

Of the ones measured here, Plausible, Vercel Web Analytics and Fathom are around 1 to 2 KB gzipped. Several others, invisit included, sit between 3 and 10 KB. Google Analytics 4 is the heaviest by far, at roughly 150 KB gzipped.

Why is gtag.js so big?

gtag.js is Google’s tag platform, not just a page view counter. It carries the code for Google Ads, consent mode, enhanced measurement and more, whether a site uses them or not.

Does a 100 KB script slow my site down?

Usually less than the number suggests on a fast laptop, and more on a mid-range phone. Scripts loaded with async or defer don’t block the first paint, but the browser still has to download, parse and run them, which competes with your own code for the main thread.

Why don’t these numbers match what my network panel shows?

Your browser shows what the CDN actually sent, which depends on its compression settings and your browser. Here every script is compressed the same way so they can be compared. Some scripts also change size over time, or by account, so the date matters.

How big is invisit’s script?

About 9 KB gzipped for the core invisit.js. Heatmaps, the feedback widget and interaction tracking are separate modules that load only on sites that turn them on.

More free tools