Skip to content
FunnelGuard

Fix guide by FunnelsGuard

Third-party scripts over half your page weight: how to fix it

PRF-083Medium impactCould addBy FunnelGuardPublished Updated
On this page

What this issue is

A third-party script is code your page loads from a domain you do not own: Google Tag Manager, a Meta Pixel, a live chat widget, a review badge, a font host, a video player or a heatmap tool. Each one adds a request, bytes to download and JavaScript the browser must run.

This issue applies when those scripts add up to more than half of the total transfer size of the page. It is common on landing pages where every team has added one more tool over time.

Why it costs you leads or sales

Third-party code competes with your own images, CSS and form for bandwidth and for the browser's main thread. On a phone with a weak connection, the page can look ready but not respond to taps. Visitors who cannot tap your button or fill your form quickly often leave.

Third parties also add risk. If one of their servers is slow or down, your page can hang while waiting for it. Some scripts load further scripts you never chose, so the weight grows without any change on your side.

Page weight by sourceExample numbers
Page weight by source (example)Your own files: 700 KB; Tag manager and tags: 450 KB; Chat widget: 400 KB; Video and social embeds: 300 KB; Heatmap and A/B tools: 150 KB0268537700450400300150Your own filesTag manager and tagsChat widgetVideo and social embe…Heatmap and A/B toolsKB

Example: a landing page of 2,000 KB where third-party code is 1,300 KB, well over half. Your own HTML, CSS, images and fonts are the smaller share.

How heavy third parties hurt a lead form
  1. Visitor landsPage starts loading on mobile
  2. Third-party scripts downloadChat, pixels, embeds compete with your content
  3. Page slow to respondTaps and typing are delayed
  4. Form submittedMany visitors leave first

The break is the main thread being busy with third-party code when the visitor tries to act.

How to check if your site has it

Measure third-party weight in Chrome
  1. Open DevTools on a private window

    Open your landing page in an Incognito window so extensions do not add requests. Press F12 and go to the Network tab.

  2. Reload with cache disabled

    Tick Disable cache, then reload. Wait until the page settles.

  3. Group by domain

    Use the Domain column (right-click the column headers to add it) and sort by Size. Add up bytes from domains that are not yours.

  4. Cross-check with Lighthouse

    Run Lighthouse in DevTools or PageSpeed Insights. The audit Reduce the impact of third-party code lists each provider with its transfer size and main-thread time.

  5. Test on a slow profile

    In the Network tab choose Slow 4G throttling and reload to see what a mobile visitor waits for.

How to fix it

Reduce third-party weight
  1. List every third-party host

    Export or copy the domains from the Network tab. Next to each, write who owns it and what it is for.

  2. Remove what nobody uses

    Old A/B tests, retired ad pixels, unused heatmaps and duplicate analytics are the easiest wins. Keep only tags that feed a report or campaign someone still uses.

  3. Replace heavy embeds with light ones

    Use a click-to-load facade for video and maps, and a plain link instead of a social feed where the feed adds nothing.

  4. Delay non-essential scripts

    Chat, heatmaps and review widgets rarely need to load before the page is usable. Load them after the first interaction or after the page has loaded.

  5. Load only what a page needs

    Do not load the chat widget or a checkout tool on pages that never use them. Scope tags to the pages that need them.

  6. Self-host static assets where the licence allows

    Fonts and small libraries can often be served from your own domain, which removes extra connections.

Where to make the change
  1. Audit tags

    In Tags, review each tag and pause or delete those no one uses. Use Preview mode to see what fires on the landing page.

  2. Tighten triggers

    Change All Pages triggers to specific pages or events. For non-essential tags use a Window Loaded trigger or a custom event after interaction.

Load a chat widget only after the first interactionjavascript
<script>
(function () {
  var loaded = false;
  function loadChat() {
    if (loaded) return;
    loaded = true;
    var s = document.createElement('script');
    s.src = 'https://chat.example.com/widget.js'; // replace with your vendor's URL
    s.async = true;
    document.head.appendChild(s);
  }
  ['scroll', 'pointerdown', 'keydown'].forEach(function (e) {
    window.addEventListener(e, loadChat, { once: true, passive: true });
  });
  setTimeout(loadChat, 8000); // fallback
})();
</script>
Before and after a third-party clean-up

Before

  • Third parties are over half of the transferred bytes
  • Chat, heatmap and old pixels load on every page
  • Slow response to taps on mobile

After

  • Only active tags load, scoped to the right pages
  • Chat and heatmaps load after interaction
  • Your own content and form load first

How to confirm it's fixed

Confirm checklist
  • Reload in Incognito with cache disabled and total third-party bytes are well under half of the page
  • Lighthouse third-party impact shows fewer providers and less main-thread time
  • The form, checkout and buttons still work on mobile
  • Conversions still appear in GA4 and your ad platforms
  • The chat widget still appears after interaction

How to prevent it happening again

Third-party weight grows quietly. Treat every new script as a cost.

Habits that keep it down
  • Name an owner for every third-party tool and review the list each quarter
  • Ask before adding a tag: who reads the data and what is the weight
  • Add a page weight and third-party check to your release routine
  • Remove a tool's script when you cancel its subscription
  • Re-run Lighthouse after each marketing tool is added

How FunnelGuard handles this

FunnelGuard does not check this yet. Measuring third-party share of page weight, with the host recorded for each request, is a possible future check.

What FunnelGuard does cover nearby: a robot visitor runs your real journeys on a schedule, such as lead forms and checkouts, and checks each step, the tracking hits sent to ad and analytics platforms, and whether test leads arrive. If a heavy or broken script stops a form or a tag from working, that failure shows up as a failed step or missing hit, re-checked from a second region before one alert with a screenshot and a likely cause.

To watch page weight today, run Lighthouse or PageSpeed Insights on your key pages monthly and after every tool is added, and keep a note of the third-party total. The free FunnelGuard plan (1 site, 2 journeys, daily checks, no card) can watch that your main journey still works while you trim scripts.

Quick timeline of how it builds up

How third-party weight creeps up
  1. Month 1

    Launch with analytics and one ad pixel. Page is light.

  2. Month 4

    Chat widget and heatmap tool added by different teams.

  3. Month 8

    Review badge, video embed and A/B tool added. Old pixels never removed.

  4. Month 12

    Third parties outweigh your own content and mobile visitors wait.

Questions people ask

Why are third-party scripts slowing down my website?

Each third-party script needs its own download, connection and JavaScript execution, and these compete with your own content. Chat widgets, tag managers, ad pixels and embeds add up quickly. Lighthouse's third-party impact audit shows which providers cost the most.

How do I see how much of my page is third-party code?

Open Chrome DevTools, go to the Network tab, reload with cache disabled and sort by the Domain column. Add up the size of requests from domains that are not yours. Lighthouse also lists third-party providers with their transfer size and main-thread time.

How much third-party code is too much?

There is no official limit, but when third-party code is more than half of the page weight, your own content is likely competing with code you do not control. Also look at main-thread time, since a small script can still be slow.

Can I just remove all third-party scripts?

No. Analytics and ad tags are often needed to measure and optimise campaigns. Remove the ones nobody uses, and delay the non-essential ones such as chat and heatmaps until after the page is usable.

Does Google Tag Manager count as a third-party script?

Yes. The container itself is loaded from Google's domain, and every tag inside it adds more requests. Pause unused tags and tighten triggers so tags only fire on the pages that need them.

Will delaying scripts hurt my conversion tracking?

It can if a conversion tag has not loaded before the visitor acts or leaves. Delay chat and heatmaps first, keep conversion tags early, and test that conversions still appear after any change.

Does FunnelGuard check third-party script weight?

Not yet. It is a possible future check. FunnelGuard does run your real journeys on a schedule and checks steps, tracking hits and test lead delivery, so a script that breaks a form or tag would show up as a failure.

Does FunnelGuard catch this?

Could add

Not checked yet: could be added to FunnelGuard.

Stop finding out from your customers

FunnelGuard runs your real forms and checkouts on a schedule, checks the tracking and the leads behind them, and alerts you once, with a screenshot. Try any paid plan free for 3 days.