On this page
What this issue is
A third-party script is JavaScript on your page that comes from a domain you do not control. Common examples are Google Analytics 4, Google Ads and Meta pixels, live chat, booking widgets, review badges, heatmaps, A/B testing tools, cookie banners, embedded videos and social feeds.
Why it costs you leads or sales
Slow pages lose visitors before they see your offer or form. Third-party code also competes with your own content for the browser's attention, which can delay the main image or headline (LCP), push layout around (CLS) and make taps respond late (INP). Google uses these Core Web Vitals as part of its page experience signals, and mobile visitors on mid-range phones feel the weight most.
Example: illustrative load times for the same page as third-party scripts are added. Your numbers will differ.
- Ad clickVisitor lands on the page
- Third-party scripts loadChat, pixels and widgets compete with your content
- Page usableForm and button appear late
- Lead submittedVisitor has already left
A slow third-party script delays the page, so the visitor leaves before the form step.
How to check if your site has it
Run a speed test on a key page
Test your landing page or checkout in PageSpeed Insights. Open the diagnostics and look for 'Reduce the impact of third-party code' and 'Reduce JavaScript execution time'. Test the mobile result first.
List every external domain
In Chrome, open DevTools, go to the Network tab, reload the page and filter by 'JS'. Sort by Domain. Anything not on your own domain is third-party.
Measure the cost of each
In the Performance tab, record a page load and check the Bottom-Up view grouped by domain. Note which ones use the most main-thread time or size.
Match each script to an owner and purpose
For each one, write down who asked for it and what it is for. Anything with no owner or purpose is a candidate to remove.
Check your tag manager tooGoogle Tag Manager
If you use Google Tag Manager, open the container and list all published tags and their triggers. Look for tags firing on All Pages that only matter on one page.
| Script type | Usually needed early? | Typical approach |
|---|---|---|
| Analytics and ad conversion tags | Yes, but can be async | Keep, load async, remove duplicates |
| Live chat widget | No | Load after interaction or after page load |
| Heatmaps and session replay | No | Run on selected pages only, or remove |
| Embedded video or maps | No | Use click-to-load placeholder |
| Social feeds and badges | No | Remove or replace with a static link |
| Old or unused pixels | No | Delete |
How to fix it
Work in this order: remove, then limit to the pages that need it, then delay, then replace with lighter options. Removing is the biggest win and the safest.
Remove scripts nobody uses
Delete old pixels, trial tools, duplicate analytics tags and widgets with no owner. Keep a note of what you removed in case something breaks.
Fire tags only where needed
Replace All Pages triggers with page-specific ones. A heatmap or booking widget does not need to load on every page.
Load non-essential scripts later
Chat, surveys and feeds can wait until the page has loaded or the visitor interacts. Use async or defer, or a delayed trigger.
Replace heavy embeds
Show a thumbnail for videos and load the player on click. Use a static map image linking to the live map.
Re-test and compare
Run the same page test again on mobile and compare script time and load metrics with your first result.
Find where scripts come from
Scripts come from plugins, the theme and header or footer code boxes. Deactivate plugins one at a time on a staging copy and see which external requests disappear.
Remove or limit plugins
Delete plugins you do not use. If a plugin has a setting to load only on certain pages, use it. A script manager or asset-control plugin can also disable a script on specific pages.
Delay non-essential scripts
If your caching or performance plugin has a 'delay JavaScript execution' option, add chat or widget scripts to it, then test your forms and checkout.
Review installed apps
In Shopify admin, go to Apps and remove those you no longer use. Some apps leave code behind, so also check the theme code.
Clean leftover code
Go to Online Store, Themes, Edit code, and search theme.liquid for script tags from removed apps. Duplicate the theme first so you can roll back.
Check customer events
In Settings, Customer events, review pixels you added and remove the ones that are no longer used.
Audit the container
List all tags. Pause or delete those with no owner. Use Preview mode to see which tags fire on each page.
Tighten triggers
Change All Pages triggers to Page Path or Page URL conditions where possible.
Delay low-priority tags
Use a Window Loaded trigger for chat and other non-essential tags. Keep conversion tags on their proper events so you do not lose tracking.
Check custom code
Open Project Settings, Custom code, and review the Head and Footer boxes. Also check page-level custom code in Page Settings.
Move scripts to the footer
Put non-essential scripts in the footer code box and add async or defer where the provider allows it.
Remove unused embeds
Check pages for Embed elements holding old widgets and delete them.
Review funnel and site tracking code
Check the tracking code fields in funnel or website settings, plus per-page custom code, for old pixels and widgets.
Limit the chat widget
If the chat widget is on pages where it is not needed, turn it off for those pages or sites in its settings.
Remove duplicate tags
Make sure the same pixel is not added at both funnel and page level.
Review marketing integrations
In the dashboard, open Settings, then Custom code and Marketing integrations. Remove tags you do not use.
Set where code loads
In Custom code, choose specific pages instead of All pages, and pick Body end for non-essential scripts.
Remove unused apps
Remove Wix apps you no longer need, since many add their own scripts.
Check code injection
Go to Settings, Developer Tools, Code Injection and review the Header and Footer boxes. Move non-essential code to Footer.
Remove unused extensions
Review connected services and extensions, and disconnect those you no longer use.
Check page-level injection
Open Page Settings, Advanced, for pages with their own code and remove old snippets.
Add async or defer
Add async to independent scripts and defer to scripts that need the DOM. See the snippet below.
Load widgets on interaction
Inject chat or video scripts only after a click, scroll or a short delay.
Open early connections wisely
Use preconnect only for the one or two third-party domains you truly need early. Too many hints defeat the purpose.
<script async src="https://example.com/analytics.js"></script>
<script>
window.addEventListener('load', function () {
setTimeout(function () {
var s = document.createElement('script');
s.src = 'https://example.com/chat-widget.js';
s.async = true;
document.body.appendChild(s);
}, 2000);
});
</script>Before
- Many tags fire on every page
- Chat widget loads at the start
- Old pixels and duplicate analytics still active
- Video and map embeds load immediately
After
- Only needed tags remain
- Tags fire only on relevant pages
- Chat loads after the page is ready
- Embeds load on click
How to confirm it's fixed
- Re-run PageSpeed Insights on mobile and compare third-party code time with your first test
- The Network tab shows fewer external domains on key pages
- Your form submits and the thank-you page still loads
- Conversion events still appear in GA4 DebugView and your ad platforms
- Chat and other delayed widgets still appear and work
- No new console errors from removed scripts
Lab tests change right away, but field data in Search Console's Core Web Vitals report is based on real visits over about 28 days, so it improves more slowly.
How to prevent it happening again
- Keep a simple register of every third-party script, its owner and its purpose
- Require a reason and a named owner before any new tag is added
- Review the tag manager and code injection boxes every quarter
- Remove tools when a campaign or trial ends
- Test page speed after each new tag or app is installed
- Prefer one tool over several that do similar jobs
Month 1
Analytics and one ad pixel are added
Month 4
Chat widget and heatmap tool are added for a trial
Month 8
Agency adds extra tracking, trials are never removed
Month 12
Pages feel slow on mobile and nobody knows why
How FunnelGuard handles this
FunnelGuard detects this issue only partly. When its robot visitor runs your journeys, it reports third-party failures, meaning external requests that fail during the run. It does not score the number of third-party scripts on a page, so it will not tell you that you have too many or how much they slow you down.
Questions people ask
Why are third-party scripts slowing down my website?
Each third-party script needs its own network request, download and processing time, and it runs on the visitor's device. Many scripts together compete with your own content for the browser, which delays the page and makes it feel unresponsive, especially on mobile.
How do I find which third-party scripts are on my site?
Open Chrome DevTools, go to the Network tab, reload the page and filter by JS, then sort by Domain. Any domain that is not yours is third-party. PageSpeed Insights also lists third-party code and its impact under its diagnostics.
How many third-party scripts is too many?
There is no fixed number. What matters is how much they delay your key pages and whether each one is needed. If a script has no clear purpose or owner, or slows your main content, it is one too many.
Do third-party scripts hurt SEO?
They can, indirectly. Heavy scripts can worsen Core Web Vitals such as LCP and INP, which feed into Google's page experience signals. Slow pages also lose visitors, which hurts conversions whatever your rankings are.
How do I make third-party scripts load faster?
Remove the ones you do not need, load the rest only on the pages that need them, and add async or defer. Delay chat, heatmaps and feeds until the page has loaded, and use click-to-load for videos and maps.
Will removing tracking scripts break my analytics?
Only if you remove the wrong ones. Remove unused and duplicate tags, keep your conversion tags, and then check GA4 DebugView and your ad platforms to confirm events still arrive.
Does Google Tag Manager slow my site down?
The container itself is small, but every tag it loads adds weight. A container with many tags firing on all pages can slow things. Tighten triggers, delete unused tags and delay low-priority ones.
Can FunnelGuard tell me if I have too many third-party scripts?
Not fully. FunnelGuard reports third-party failures during its journey runs but does not score how many scripts a page loads. Use PageSpeed Insights and the browser Network tab for the count and impact.