5 Signs Your Shopify Theme Is Full of Dead App Code (And How to Check)
Most multi-shop retailers have a long history of trying tools that looked promising and then quietly abandoning them. The digital equivalent of that — on Shopify — is uninstalling apps and assuming the job is done.
It may not be done. Some apps uninstall cleanly; others can leave files or references. A leftover only affects runtime when the storefront still references, renders, downloads, or executes it.
Most merchants do not realise this is happening until something forces them to look: a performance audit, a developer poking around the theme, or a PageSpeed score that should not be that low. By then, the code has often been accumulating for a year or two.
These five clues justify a closer look. None of them proves that a particular file is unused or safe to remove.
Disclosure: ThemeSweep is built by JMS Dev Lab, the publisher of this blog. I will mention it at the end, but you do not need it to do any of the checks below.
Sign 1: Your PageSpeed Score Dropped After Uninstalling an App
This sounds backwards, but it is surprisingly common. You uninstall a heavy app expecting your score to improve — and it does not. Sometimes it gets worse.
One possibility is a script or stylesheet that remains referenced after the app is gone. Other causes include images, theme changes, active apps, tag managers, or third-party services, so inspect the network waterfall before assigning blame.
A score change by itself is not attribution. Look for a specific request, its initiator, timing, and behaviour on the affected page.
Quick check: Run your store through Google PageSpeed Insights. Then open Chrome DevTools (F12 or right-click → Inspect), go to the Network tab, reload your page, and filter by Status: failed or look for any requests showing 400–499 or 500–599 status codes. Failed requests from app CDNs or external domains are a strong indicator of orphaned scripts still trying to phone home.
Sign 2: You See JavaScript Console Errors on Your Storefront
Your customers do not see these. But your browser does — and they slow your store down.
When an app is uninstalled but its JavaScript is still in your theme, the script loads and immediately starts looking for DOM elements that no longer exist. Things like document.getElementById('app-widget-container') returning null because the app was responsible for creating that element. The script throws an error, which can block subsequent scripts from executing cleanly.
Multiple orphaned scripts doing this simultaneously — each one throwing errors, each one adding to your Total Blocking Time — and you have a store that feels sluggish even with fast hosting and compressed images.
Quick check: Open the Console and Network panels, reload the page, and note errors or failed requests. An unfamiliar app name is a clue. Confirm who owns the resource and whether the current storefront still needs it.
Sign 3: Your Theme Has More Files Than You Can Account For
A standard Shopify theme has a predictable file structure: templates, sections, snippets, assets, config, layout, locales. When you add apps, they inject additional files. When you uninstall apps, those files usually stay.
App-style filenames can help you form a review list. They do not prove the file has no current reference or that another customization does not depend on it.
The number of files alone is not useful evidence. A large theme may legitimately contain more assets, and an unreferenced file does not add page weight merely by existing.
Quick check: In Shopify admin, open the theme code editor and look for app-style names in Snippets and Assets. Confirm the related app is gone, search the theme for references, and account for dynamic Liquid filenames. Add uncertain items to a review list rather than deleting them.
Sign 4: Your Store Loads Slowly Even Though Your Images Are Optimised
Images are the first thing merchants optimise when their store is slow, and rightly so — uncompressed images are responsible for most avoidable load time. But if you have already compressed and sized your images correctly and your store is still slow, the problem is probably JavaScript.
JavaScript is render-blocking by default. When a browser loads your page, it stops rendering when it hits a script tag until that script is downloaded and executed. Modern themes use async and defer attributes to mitigate this, but orphaned app scripts often do not — they were injected by the app’s installer, which may not have followed best practices.
A render-blocking resource can affect loading, but its cost depends on size, cache state, connection, execution, and page context. Measure the individual request instead of applying a fixed delay.
Quick check: Open your store’s homepage in a browser and right-click → View Page Source (the raw HTML, not Inspect Element). Use Ctrl+F to search for <script. Count how many script tags appear before the closing </head> tag. More than 8–10 is worth investigating. Then look at the src attributes on those script tags — any pointing to external CDN domains you do not recognise are potential dead app scripts.
Also search the rendered source and network requests for names associated with removed apps. A match proves only that the string or request appears on the page you checked; investigate its initiator and purpose.
Sign 5: Your Lighthouse Score Dropped After Adding Apps, and Never Recovered
This one is about patterns over time rather than a single snapshot. Merchants who track their Lighthouse scores regularly notice a creeping decline — the score was 88 when they launched, then 81, then 74, with no obvious single cause.
App churn is one possible contributor, alongside images, theme updates, active integrations, consent tools, analytics, and other third-party resources.
The tricky part is that no single app is obviously responsible. The score did not drop sharply when you uninstalled the reviews widget last month. It dropped by 3 points. And by 2 points the month before, and by 4 points six months ago. The damage is distributed across multiple orphaned scripts, making it hard to diagnose without a systematic audit.
Quick check: Run your store through PageSpeed Insights and look at the Opportunities and Diagnostics sections. Pay specific attention to:
- Eliminate render-blocking resources — lists scripts and stylesheets that are blocking your page render. Any app CDN URLs in this list that belong to uninstalled apps are dead code.
- Reduce unused JavaScript — shows the actual kilobytes of JavaScript being downloaded but not executed. This is often the clearest signal of orphaned scripts.
- Reduce unused CSS — same for stylesheets. Orphaned app CSS is a common contributor.
If PageSpeed is flagging large amounts of unused JavaScript from external domains, you have accumulated dead code. How much depends on how many apps you have tried over the lifetime of your store.
What to Do About It
You have three paths once you confirm you have dead code.
Manual cleanup is free and gives you full control. Open your theme code editor, identify the orphaned files and script tags, and delete them carefully. Back up your theme first — always. This approach works well if you have a short app history and a simple theme. Budget 2–3 hours for a thorough manual audit.
Hiring a developer is the safest manual option. A Shopify developer who knows their way around Liquid and theme architecture can audit and clean up your theme without breaking anything. Expect £150–£400 for a one-off cleanup.
Using a diagnostic tool can make the review repeatable. ThemeSweep scans supported theme text files using static-reference analysis and known app-code signatures, then reports evidence, confidence, and a likely source when recognised. Shopify does not give ThemeSweep an authoritative list of the merchant’s other installed apps, so every finding still requires review. Selected cleanup is revalidated and prepared on a duplicate theme, with file backup and rollback available for 30 days.
The Free plan includes unlimited diagnostic scans and one cleanup for one reviewed finding. Paid plans start at $9.99 USD per month. Scan duration depends on the theme. ThemeSweep is listed on the Shopify App Store.
If you found any of the five signs above in your own store, it is worth running the scan just to see the full picture. Most merchants are surprised by how much has accumulated.
Related Reading
- The Hidden Cost of Uninstalling Shopify Apps — The full technical explanation of why app code stays behind, what it does to your performance, and what you can do about it.
- How to Evaluate Theme Cleanup Tools — Compare evidence, uncertainty, preview, and rollback.
Need Help?
If you are not sure what you are looking at in your theme code, or you want a second opinion on your PageSpeed results, get in touch. Happy to take a look.
Related reading: How to Speed Test Your Shopify Theme (And What To Do When It Fails) · Shopify Theme Audit Tools Compared: Which One Is Worth Running · The Hidden Cost of Uninstalling Shopify Apps · How to Evaluate Theme Cleanup Tools · ThemeSweep.
Have an awkward problem like this one?
Send us one workflow. JMS Dev Lab will recommend the most sensible next step: build, buy, automate or wait.
— or leave your email for one practical reply, with no newsletter —