Whether you’re deploying a site from your local environment to the live server, or pulling a live site down to local, there are some plugins that just seem to get in the way of a smooth migration, like bumps in a road. We hope you find these tips & tricks helpful.
Caching – Common examples of caching plugins are W3 Total Cache and WP Super Cache. These plugins save server load by creating a static file version of your site to deliver to web users, rather than having them dynamically generated on each page view.
If you use any of these plugins, here are some steps to take before moving a site from live to local, or the other way around):
- Deactivate the plugin in question.
- Delete the “cache” folder (this is usually somewhere in wp-content, but might also be in the root directory of WordPress)
- Check your wp-config.php for any lines added by the plugin and remove them.
Any plugin that creates a cached version of files on the site should be deactivated before moving the site. Not doing so can cause the site to be broken in its new location until the plugin is deactivated and the cache is cleared.
Jetpack – Jetpack brings a ton of great features of WordPress.com to your self-hosted WordPress site. Many of its features, though, rely on a connection to WordPress.com in order to function. Before downloading a live site to your local environment, you’ll want to deactivate Jetpack so it doesn’t try to connect the local version to WordPress.com.
To develop locally with Jetack, you can add define( ‘JETPACK_DEV_DEBUG’, true); to the wp-config.php file. This disables the connection to WordPress.com, while allowing you to use all of the features that don’t rely on the external connection.
Unfortunately it does not appear that Jetpack’s Photon feature honors the JETPACK_DEV_DEBUG mode flag. If you are using Jetpack’s Photon feature, we’d recommend you simply turn the CDN service off during development by disabling the Jetpack plugin or just rename the wp-content/plugins/jetpack folder to jetpack-sav after importing your website.
Hide My WP – This plugin claims to help prevent hackers getting into your site by hiding or changing the WordPress file structure. The wp-admin, plugins, and upload urls (and many others) are all changed or removed. DesktopServer relies on the standard file structure being present, so make sure to deactivate this (or any similar) plugin before pulling a live site to local.
Coming Soon/Maintenence – There are a ton of plugins out there that will display a “Coming Soon” or other maintenance message, or otherwise hides the site from view of users that aren’t logged into the site. Before deploying, you’ll want to make sure these plugins are deactivated, as they will cause the deploy to fail if they are turned on. Also, if you’re using a “.maintenance” file to hide the site, you’ll want to delete/rename it. If you need the site to be hidden once deployed, simply reactivate your plugin or add back the “.maintenance” file.
Have you run into any other plugins that cause issues? Let us know in the comments!
Marc’s driven spirit moves ServerPress, LLC forward with elevated momentum. With his business expertise, he rolls up his sleeves helping the Team in every possible way to ensure a smooth Workflow. Besides work, Marc is a big Advocate for Foster Care. Yes. 8 kids and counting…