--skip-plugins flag.
Impact: the whole site and wp-admin return 500
Investigation: prove it's a plugin before changing anything
wp-config.php), and run commands as the site's own system user rather than root.
The --skip-plugins flag tells WP-CLI to load WordPress core without loading any plugins. It affects only that one command. Nothing is deactivated, no option changes in the database, and visitors still get the same broken site. That makes it a safe first test.
BASH
# Run from the WordPress root as the site user
wp option get home
wp option get home --skip-plugins
# Check what visitors actually see
curl -sI https://example.com | head -n 1wp-config.php are fine.
If both commands fail, the cause is somewhere else: the theme (try adding --skip-themes), a broken core file, a database error, or a syntax error in wp-config.php itself. If both commands succeed but curl still shows a 500, the failing code may only run during web requests, for example on an admin or front-end hook that WP-CLI never triggers. The web server's error log becomes your main source at that point.
WP-CLI loads PHP through the CLI binary, and the CLI binary can be a different PHP version from the one serving the site. If the error doesn't reproduce in the terminal, run wp --info and compare its PHP version with what the control panel says the site uses. A plugin that requires a newer PHP than the site runs is a common reason an update breaks things.
The discovery: one plugin, named in the error
--skip-plugins also accepts a comma-separated list of slugs, and then it skips only those. Skipping one plugin at a time, while all the others load, isolates the culprit without deactivating anything:
BASH
# List active plugins without loading them
wp plugin list --status=active --field=name --skip-plugins
# Skip one plugin at a time; the one that makes the command succeed is the suspect
for p in $(wp plugin list --status=active --field=name --skip-plugins); do
if wp option get home --skip-plugins="$p" >/dev/null 2>&1; then
echo "Loads fine when skipping: $p"
fi
done--skip-plugins=plugin-a,plugin-b, and remove names from the list until the error comes back.
The skip loop tells you which plugin to suspect. The PHP error log tells you why. When WP-CLI prints the fatal error, the message usually contains a file path such as wp-content/plugins/some-plugin/includes/..., along with the line number and the error type. If the terminal shows nothing useful, check the logs the web requests write to. Where those are depends on the setup. On many cPanel servers there is an error_log file in the document root or in wp-admin. On PHP-FPM setups there may be a pool-level log. If WP_DEBUG_LOG is enabled, WordPress writes to wp-content/debug.log unless the path was changed. If you turned debugging on and the log stays empty, check where debug.log is actually writing.
The error type points to the right fix:
- Call to undefined function or class not found: the plugin depends on something missing, often another plugin or a newer PHP extension.
- Allowed memory size exhausted: the code may be fine, but it needs more memory than PHP allows. Raising the limit is then a reasonable fix.
- Syntax error: often means the plugin requires a newer PHP version than the site runs, or the update didn't finish copying its files.
Mitigation: deactivate, confirm, then roll back
BASH
# Deactivate only the culprit (settings stay in the database)
wp plugin deactivate plugin-slug --skip-plugins
# Confirm the site loads again
wp option get home
curl -sI https://example.com | head -n 1
# Optional: reinstall the previous version (1.2.3 is a placeholder)
wp plugin install plugin-slug --version=1.2.3 --force --skip-plugins
wp plugin activate plugin-slugwp plugin install --version only fetches versions hosted on wordpress.org. Premium or custom plugins need a ZIP from the vendor or a copy from a backup.
Without shell access, the fallback is the File Manager or SFTP method: rename the plugin's folder inside wp-content/plugins so WordPress can't load it. If you're not sure which plugin it is, rename the whole plugins folder to something like plugins_old, confirm the site loads, rename it back, and then rename individual plugin folders one at a time. It works, but it's slower than the skip loop and easier to get wrong. Renaming the parent folder makes WordPress deactivate every plugin, and you then have to reactivate them by hand.
The longer-term fix: change how updates reach production
- Update one plugin at a time, and check the site after each one. When five plugins update together and the site breaks, you have five suspects. When one updates, you have one.
- Test larger updates on a staging copy first, especially plugins that change the database or need a minimum PHP version. A clone running the same PHP version as production catches most fatal errors before visitors see them.
- Take a backup before updating. Files and database together, so rolling back doesn't depend on wordpress.org still hosting the old version.
- Keep the admin email current and outgoing mail working, so the Recovery Mode email reaches someone.
- Be careful with auto-updates on plugins that hold critical business logic. Auto-updates are a trade-off: you get security fixes sooner, and you accept a broken release reaching production without anyone watching. For many small sites, auto-updates are still the better default. For checkout or membership plugins, many teams prefer to update by hand during a quiet period.
--skip-plugins comparison and showing the plugin path from the error log usually settles that within a few minutes and points the fix at the right place.
Here is the practical takeaway. When a 500 appears right after a plugin update, don't delete or rename anything yet. Run the same WP-CLI command with and without --skip-plugins to confirm the plugin layer is the cause. Skip one plugin at a time to find the suspect, and read the error log to learn why it fails. Then deactivate that one plugin, get the site back, and roll back or fix forward once you know what changed.