Skip to content
New: GA4 dashboards, server-side conversions to every ad platform, Consent Mode v2 generation, and publish approvals.See what shipped
performance

A performance budget for marketing scripts, and how to stay under it

Tracking scripts are usually the heaviest JavaScript on a page, and they move Largest Contentful Paint. A budget of 200 KB, a way to measure it, and the three changes that get most sites under it.

3 min readBy TagEasy
All posts

Nobody budgets for marketing scripts, which is why they grow until the site is slow. The audit's script weight check gives sites a pass under 200 KB of identified tracking and tag-management JavaScript, a warning up to 400 KB, and a failure above that. As of October 2026, 96 percent of audited sites pass, which sounds good until you look at the ones that do not: they are usually large stores with the most to lose from a slow page.

Why 200 KB

It is not a magic number. It is roughly the point where the tag manager, GA4, one advertising pixel and one session tool fit comfortably, and where adding a second of everything starts to show in Largest Contentful Paint on a mid-range phone. Google's own guidance puts third-party JavaScript high on the list of causes of poor LCP and Total Blocking Time, and marketing tags are the third-party JavaScript on most commercial sites.

Measuring what you actually ship

Open the browser's network panel, filter to JavaScript, and reload the homepage with cache disabled. Sort by size and add up everything served from a tag or analytics vendor: the GTM container, the gtag library, each pixel's base script, session replay, heatmaps, chat. Then do the same on a product page, where app-injected scripts tend to appear.

The free audit does this on every run and reports the total.

The three changes that fix most sites

  1. Remove dead tags. A vendor script for a tool you no longer use is pure cost. Most sites over budget have at least one.
  2. Load non-essential tags after interaction. Chat widgets, surveys and session replay do not need to load before the page is usable. Fire them from a trigger on first scroll or after a timer rather than on page view.
  3. Move advertising conversions server-side. A server container forwards GA4, Google Ads and Meta events from one browser request, which replaces several vendor scripts with one lightweight call. This is the single biggest reduction available, and it also improves data quality under ad blockers.

What not to do

Do not delay GA4 or the consent banner. Delaying the consent banner means tags may fire before the visitor has answered. Delaying GA4 loses the page view for visitors who bounce quickly, which skews bounce and engagement metrics for every page.

Keeping it under budget

Add the script weight number to whatever dashboard the marketing team already looks at, and alert when it jumps. A 100 KB increase in a week means somebody installed something, and that is the week to ask what and why, not the quarter after.

FAQ

How much JavaScript should tracking add to a page?

Under 200 KB of compressed JavaScript is a reasonable budget for a tag manager, analytics, one or two advertising pixels and a consent banner. Beyond 400 KB, the tracking stack is likely to be visible in page speed metrics.

Does Google Tag Manager slow down a site?

The container itself is small. What slows a site is the vendor scripts the container loads. A container with ten live vendor scripts on page view is heavy regardless of whether GTM or hardcoded tags load them.

Can server-side tagging reduce page weight?

Yes. One request from the browser to your server container can be fanned out to GA4, Google Ads, Meta and others server to server, replacing their browser scripts. It is the largest single reduction most stores can make.

Check your script weight on any URL at tageasy.io/check.

Keep reading

Related posts

See where your tracking stands

Run the same 17-check audit referenced in this post against any URL. No signup, results in seconds.