Title: Remove unused javascript
Last modified: June 2, 2020

---

# Remove unused javascript

 *  Resolved [akashkms01](https://wordpress.org/support/users/akashkms01/)
 * (@akashkms01)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/remove-unused-javascript/)
 * My pagespeed is low and i want to increase it
 * The main problem shown on the google pagespeed is
    Remove unused javascript and
   server image on next-gen format
 * Please help me to resolve this issue.
 * Because of this issue my bounce back rating is 100%.
 * Resolve my issue ASAP
    thank you
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fremove-unused-javascript%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [gooma2](https://wordpress.org/support/users/gooma2/)
 * (@gooma2)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/remove-unused-javascript/#post-12968343)
 * Hello,
 * I’m having the same issue also and it’s showing for cache/asset cleanup files.
 * Hoping there an answer for this as Google Pagespeed Lighthouse has done some 
   major changes and are demanding more than ever.
 * Thank you!
 *  Plugin Author [Gabe Livan](https://wordpress.org/support/users/gabelivan/)
 * (@gabelivan)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/remove-unused-javascript/#post-12994620)
 * [@akashkms01](https://wordpress.org/support/users/akashkms01/) [@gooma2](https://wordpress.org/support/users/gooma2/)
   Indeed, Google PageSpeed introduced some changes such as “_Remove unused JavaScript_”
   which is even more difficult to remove than the CSS as Coverage DevTools which
   is often used to determine unused bytes is less accurate (due to the nature of
   the JS code, not the tools fault I would say) to detect which JS files are needed
   and which not.
 * [@akashkms01](https://wordpress.org/support/users/akashkms01/) on your website,
   there are still asserts that are likely not needed and can be unloaded, including:
   –
   [https://thefreegyaan.com/wp-includes/css/dist/block-library/style.min.css](https://thefreegyaan.com/wp-includes/css/dist/block-library/style.min.css)–
   [https://thefreegyaan.com/wp-content/plugins/pwa-for-wp/assets/css/pwaforwp-main.min.css](https://thefreegyaan.com/wp-content/plugins/pwa-for-wp/assets/css/pwaforwp-main.min.css)–
   [https://thefreegyaan.com/wp-content/plugins/easy-table-of-contents/vendor/icomoon/style.min.css](https://thefreegyaan.com/wp-content/plugins/easy-table-of-contents/vendor/icomoon/style.min.css)–
   [https://thefreegyaan.com/wp-content/plugins/easy-table-of-contents/assets/css/screen.min.css](https://thefreegyaan.com/wp-content/plugins/easy-table-of-contents/assets/css/screen.min.css)–
   [https://thefreegyaan.com/wp-includes/js/wp-embed.min.js](https://thefreegyaan.com/wp-includes/js/wp-embed.min.js)
 * Currently, Asset CleanUp supports unloading whole CSS/JS files. You can’t strip
   partial code from specific files. There are ways to unload a CSS/JS file and 
   load an alternative (lighter) version of that file with considerably less code,
   thus, reducing the total page size and having it load faster by the browser. 
   Based on my experience, this is worth implementing for pages with high traffic.
   I’ve noticed CSS code that was unused in 90% of the cases and it was worth going
   through it (sometimes you spend hours testing and making sure the page looks 
   exactly the same) in order to reduce hundreds of KB and have a faster loading
   page.
 * I’m considering providing more tutorials/documentation about removing unused 
   CSS/JS as it’s one of the most popular topics out there, along with reducing 
   render-blocking resources.
 * [@gooma2](https://wordpress.org/support/users/gooma2/) _I’m having the same issue
   also and it’s showing for cache/asset cleanup files._ – the reason it’s making
   reference to Asset CleanUp is that you have minified/combined or enabled an option
   that would alter the original file and has to store the optimized version in 
   the cache.
 * Even if you weren’t using Asset CleanUp, the original file would still be reported
   as render-blocking or having unused code. So, Asset CleanUp did make changes 
   to that file (e.g. it minified it), but for Google PageSpeed, it still has unused
   code there. I hope it makes sense!
 * In fact, there were quite a few people that mentioned this and thought that Asset
   CleanUp is adding render-blocking resources to pages which is completely false,
   it will never do that as it’s against the purpose of the plugin. I’ll make sure
   the documentation has a dedicated post about this clarifying this in detail so
   there will be no doubt about how this works.
 *  Thread Starter [akashkms01](https://wordpress.org/support/users/akashkms01/)
 * (@akashkms01)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/remove-unused-javascript/#post-12997803)
 * SO sir how to remove unused javascript? please tell me so that i can icreasing
   page speed.
 * My bounce back rate is increasing day by day. Currently it is 70.22%
    Please 
   do help

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Remove unused javascript’ is closed to new replies.

 * ![](https://ps.w.org/wp-asset-clean-up/assets/icon-256x256.png?rev=1981952)
 * [Asset CleanUp: Page Speed Booster](https://wordpress.org/plugins/wp-asset-clean-up/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-asset-clean-up/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-asset-clean-up/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-asset-clean-up/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-asset-clean-up/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-asset-clean-up/reviews/)

 * 3 replies
 * 3 participants
 * Last reply from: [akashkms01](https://wordpress.org/support/users/akashkms01/)
 * Last activity: [5 years, 10 months ago](https://wordpress.org/support/topic/remove-unused-javascript/#post-12997803)
 * Status: resolved