I found that after uninstalling the apps, the page will have a lot of unused code, affecting the speed of the page. Is there any apps that can clear all unused code of the website?
Topic summary
Core Issue:
Shopify store owners struggle with leftover code from uninstalled apps that slows page speed. No automated app exists to clean this code.
Key Findings & Solutions:
-
Shopify’s New Requirements: As of ~2 months ago, Shopify requires apps to provide automatic code removal upon uninstallation. Users should reinstall apps briefly to check for cleanup buttons.
-
Diagnostic Approach: Use Chrome DevTools (right-click → Inspect → Network tab) to identify slow-loading resources and trace them to specific apps or theme files.
-
Common Culprits:
- Facebook Pixel requests (often duplicated, sometimes 3+ instances)
- Review apps (Ali Reviews, Judge.me, Yotpo, Opinew)
- Loyalty/rewards programs
- Chat widgets and email marketing tools
- Unused CSS/JavaScript from themes
-
Recommended Actions:
- Contact app developers for optimization help
- Add
loading="lazy"to image tags for lazy loading - Search theme files for app references using text editors
- Consolidate duplicate pixels/tracking codes
- Remove unused apps completely following developer uninstall guides
Important Caveats:
- Some JavaScript loads after main page (via Shopify script tags), so doesn’t actually slow initial load despite Google reports
- Theme core files shouldn’t be modified without expertise
- Google Lighthouse scores simulate slow connections and may not reflect real user experience
- Professional developer help recommended for complex code removal
Unfortunately, there is no app in Shopify that does this work of clearing out the code.
However, we can certainly help you in removing the unused code from uninstalled app if you can provide more details to it.
Looking forward to hearing from you.
Thanks & Regards,
Perennial Solution
i have the same problem causing major problem in my store. why are these apps not required to remove all there code when the app is deleted. people should be warned about this before adding any apps. is there any tool out there to identify the location of unused code. i can delete the code if i know what file its in and how to identify the code.
Remove unused CSS
2.2 s
Remove dead rules from stylesheets and defer the loading of CSS not used for above-the-fold content to reduce unnecessary bytes consumed by network activity. Learn more.
Show 3rd-party resources (3)
URL Size Potential Savings
…admin/style-6eaaa8d….css
(cdn.shopify.com) 195 KB 194 KB
…assets/theme.scss.css?771
(cdn.shopify.com) 17 KB 13 KB
…assets/beans.css?771
(cdn.shopify.com) 2 KB 2 KB
Sorry but there are no tools available for identifying the unused code after deleting the app.
Can you help me out with this same problem?
We went through the Shopify app review process about 2 months ago and Shopify takes this issue quite seriously now.
They ask that app developers have a way to automatically remove any inputted code on the store. For example, we have a button on our ‘setup’ page. It might be worth re-installing said apps, just to make sure they don’t have an equivalent.
Cheers,
Oli
——————————
Founder [email removed] www.preproduct.io
Test and make sales for future products
Hi, Can someone help me learn how to remove unused code? Unused JavaScript causes 2.7 sec delay on my website - I am sure it’s caused from uninstalled apps. I ran speed test and after uninstalling some apps that I wanted to try but didn’t like, it made my websit mobile speed score 34, when it was around 65. Thanks!
Hi @Foresterbags ,
If you open your store on Google Chrome and then hold control and click the page, then select ‘inspect’ from the box.
Then click on the ‘Network’ tab on the top of the newly opened side panel. You should be able to see a waterfall diagram of your pages load time, maybe list out any slowly loading items (before the red line) especially if they contain the name of prior apps.
Is it your product pages that are loading slowly? or the catalogue/collection pages? If you copy and paste the code into this thread, I’m happy to have a quick look at it and see if there’s anything obvious we could take out.
Cheers,
Oli
——————————
Founder [email removed] www.preproduct.io
Test and make sales for future products
These are a few codes under “warning”
A cookie associated with a cross-site resource at was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at and .
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at http://the-everything-pro-store.myshopify.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at https://the-everything-pro-store.myshopify.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at https://myshopify.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at http://myshopify.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at http://paypal.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at http://www.paypal.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at https://paypal.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at https://www.paypal.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at http://shopifycloud.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
?_sc=1&design_theme_id=80898490470&frame_token=galQS4V8mtiNZ8WO_4g5P2pIZ1IUtbR2A6WxFKRKvuvFqdXCfa7mYCIG-zQbxC-iAOczXixo0Q3zNEwskyeBux_Rwe6BBg6q-czzeL35wwUeZMp1eEkLR1EkrZ0yTxPaf6qDXv2F_X8Qdz7X19cfcg%3D%3D:1 A cookie associated with a cross-site resource at http://recovermycart.com/ was set without the SameSite attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
gagfe-TwdZx-h9xbMHKWe1TqHx.js?shop:50=the-everything-pro-store.myshopify.com InCartUpsell library 2020-05-22 12:29:59 +0000 loaded
https://www.saintcolmar.com/collections/all-products/products/blue-light-blocking-anti-glare-glasses
https://www.saintcolmar.com/collections/all-products/products/puzzle-roll-jigsaw-storage-felt-mat
Hi Amit,
The message which is pretty much repeated throughout your log is a hot topic at the moment. Internet browsers are putting in stricter rules regarding cookies. Shopify knows about this and I think it was even talked about at the latest Shopify Unite web conference.
Basically app developers have to push an update out to fix it. I’m suprised PayPal haven’t already done this, but maybe there’s something else going on that I’m not privy to.
To summarise, that error won’t slow your site down, but it will stop certain apps functioning in future Chrome versions.
Cheers,
Oli
——————————
Founder @ www.preproduct.io
Test and make sales for future products
Hi Jack,
It seems like 'Ali Reviews’s is the app mostly slowing your product pages down.
Cheers,
Oli
——————————
Founder [email removed] www.preproduct.io
Test and make sales for future products
Hello ,
I’m having the same problem with this unused codes , please can you help me with that?
Yeah, no worries @brunashaqiraj , post your site URL and I’ll have a quick look.
——————————
Founder [email removed] www.preproduct.io
Test and make sales for future products
Thank you so much.
Here it is: www.shop.christinevalmy.com
I don’t think your sites that slow to be honest mate. The top loading times other than Shopify stuff looks like Google leads and there’s also a failed request to this URL: https://unpkg.com/eventemitter3@4.0.4/umd/eventemitter3.min.js to get come javascript, this might be important for elsewhere on your site though.
Cheers,
Oli
——————————
Founder @ www.preproduct.io
Test and make sales for future products
Hi
I have the same problem. Rosylana.com. Thanks!
Google says remove unused javascript, what can I do about it?
Hey @lsmall ,
I had a quick look at your site. There was a couple of errors you could look into, but sometimes these errors are just ungracefully managed results of fully operational apps.
The two that came up are: helpfulcrowd.com and getshowgun.com. If you’re using both of these apps, then I wouldn’t necessarily worry about it. Your product page load speed on my Mac is 1.58secs which seems pretty reasonable.
Cheers,
Oli
——————————
Founder [email removed] www.preproduct.io
Test and make sales for future products
Hey @OliUK can you help me too please my site score is just 34
here is my product page link
https://amichestore.com/collections/all/products/best-dad-ever-t-shirt
please help
Hey,
On my internet your page loaded in just over 1 second, which seems pretty good. Both Paypal and Facebook pop up in the load time.
Here’s Googles lighthouse report
Main-Thread Blocking Time
Shopify
694 KB
1,062 ms
200 KB
101 ms
Google Analytics
38 KB
17 ms
Google CDN
65 KB
16 ms
PayPal
3 KB
13 ms
Klaviyo
18 KB
0 ms
Other Google APIs/SDKs
8 KB
0 ms
Google/Doubleclick Ads
0 KB
0 ms
——————————
Founder [email removed] www.preproduct.io
Test and make sales for future products