Title: minify manual selected scripts?
Last modified: August 22, 2016

---

# minify manual selected scripts?

 *  [natostanco](https://wordpress.org/support/users/natostanco/)
 * (@natostanco)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/minify-manual-selected-scripts/)
 * It would be nice to be able to manually add scripts to the minification process.
 * Also, amazing plugin, all the minification plugins I have tried just fail one
   way or the other, including w3tc, wprocket and other plugins.
 * [https://wordpress.org/plugins/autoptimize/](https://wordpress.org/plugins/autoptimize/)

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

 *  Plugin Author [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * (@futtta)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/minify-manual-selected-scripts/#post-5952016)
 * Hi natostanco;
    That isn’t possible by default (using the settings screen) but
   with some coding against autoptimizes API this surely can be done (hooking into
   the autoptimize_js_after_minify-filter, where you could add whatever JS to the
   base autoptimized JS).
 * Hope this helps,
    frank
 *  Thread Starter [natostanco](https://wordpress.org/support/users/natostanco/)
 * (@natostanco)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/minify-manual-selected-scripts/#post-5952113)
 * yeah, but to how remove them from the page
 *  Plugin Author [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * (@futtta)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/minify-manual-selected-scripts/#post-5952116)
 * not sure I understand the use case I’m afraid; if the scripts are on the page,
   they’ll be aggregated & minified anyway, so there’s no reason to add them separately?
 * frank
 *  Thread Starter [natostanco](https://wordpress.org/support/users/natostanco/)
 * (@natostanco)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/minify-manual-selected-scripts/#post-5952119)
 * currently all the js scripts are recognized and some are minified, whereas some
   are just moved to the footer, indeed no .js scripts appear in the head or body
   except adsense ones. I would like to try to combine all the scripts moved into
   the footer, I guess the ismergeable function is forbidding the combine? Maybe
   I would like to try and bypass it.
 *  Plugin Author [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * (@futtta)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/minify-manual-selected-scripts/#post-5952145)
 * ah, ok. small warning first; do take into account that in general JS is in that
   list because it breaks when being optimized, so I’m not sure this will work OK.
 * but it can be done, hooking on to the “autoptimize_filter_js_exclude” (and optionally“
   autoptimize_filter_js_movelast”)-filters to remove any exclusion/ moving of JS.
 * good luck! 🙂
    frank

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

The topic ‘minify manual selected scripts?’ is closed to new replies.

 * ![](https://ps.w.org/autoptimize/assets/icon-256X256.png?rev=2211608)
 * [Autoptimize](https://wordpress.org/plugins/autoptimize/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/autoptimize/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/autoptimize/)
 * [Active Topics](https://wordpress.org/support/plugin/autoptimize/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/autoptimize/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/autoptimize/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * Last activity: [11 years, 2 months ago](https://wordpress.org/support/topic/minify-manual-selected-scripts/#post-5952145)
 * Status: not a support question