Title: Change cache folder path
Last modified: January 18, 2017

---

# Change cache folder path

 *  [wpbulli](https://wordpress.org/support/users/wpbulli/)
 * (@wpbulli)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/change-cache-folder-path/)
 * Hi,
 * It looks like the plugin automatically sets the cache folder to ./wp-content/
   cache/autoptimize/.
    Because of a master-slave setup, I need to move this folder
   somewhere else. Is there a way to permanently adjust this?
 * Thanks!

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

 *  Plugin Author [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * (@futtta)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/change-cache-folder-path/#post-8668861)
 * yeah, by setting the appropriate constants in wp-config.php, cfr. [the FAQ](https://wordpress.org/plugins/autoptimize/faq/)
   🙂
 *  Thread Starter [wpbulli](https://wordpress.org/support/users/wpbulli/)
 * (@wpbulli)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/change-cache-folder-path/#post-8669007)
 * Hi Frank,
 * Thanks for your reply. Sorry, I wasn’t specific enough. The available constant
   CACHE_CHILD_DIR always uses the WordPress directory as a base path but I need
   this to be somewhere completely different, e.g. /tmp/autoptimize/
 * Is there any way to achieve this?
 * Thanks!
 *  Plugin Author [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * (@futtta)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/change-cache-folder-path/#post-8669091)
 * no, afraid the AO-cache has to be the wordpress directory [@wpbulli](https://wordpress.org/support/users/wpbulli/).
 *  Plugin Author [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * (@futtta)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/change-cache-folder-path/#post-8677527)
 * late addendum; the CACHE_CHILD_DIR obviously also needs to be accessible for 
   apache and configured as such in one of the sites_available/your_site, as the
   HTML will include references to CACHE_CHILD_DIR/js/autoptimize_<md5hash>.js and
   CACHE_CHILD_DIR/css/autoptimize_<md5hash>.css

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

The topic ‘Change cache folder path’ 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/)

 * 4 replies
 * 2 participants
 * Last reply from: [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * Last activity: [9 years, 4 months ago](https://wordpress.org/support/topic/change-cache-folder-path/#post-8677527)
 * Status: not resolved