brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: wp plugin deactivate --all finds the plugin that breaks your site

Troubleshooting
~/tips/tip-wordpress-plugin-deactivate-all

wp plugin list --status=active --field=name > active-plugins.txt

Switches off all WordPress plugins at once so you can find which one breaks the site.

When a WordPress site goes white or throws errors after an update, the usual advice is to rename the plugins folder. WP-CLI has a tidier way that also lets you switch them back one at a time.

First write down which plugins are active, so you can restore the same set:

wp plugin list --status=active --field=name > active-plugins.txt

Then turn everything off:

wp plugin deactivate --all

If the site works again, a plugin was the cause. Activate them back one by one, loading the site after each, until the error returns:

wp plugin activate some-plugin

If WP-CLI itself fails because of the broken plugin, add --skip-plugins to the command so WordPress loads without them.

You can keep a few active with --exclude, for example wp plugin deactivate --all --exclude=hello,wordpress-seo.

The caveat is that deactivating changes behaviour. A caching or security plugin that goes off leaves the site unprotected for a while, and some plugins clean up settings when they deactivate. Never add --uninstall here, because that deletes the plugin’s data. Do this on a staging copy when you can, and at a quiet moment when you cannot.

Further reading: wp plugin deactivate (WP-CLI handbook)

More Troubleshooting tips Get-NetTCPConnection -State Listen modinfo -p usb_storage ps -o pid,lstart,etime,cmd -p 1234 sudo lsof -nP -p 1234 fc-match Helvetica All Troubleshooting tips (21) All topics

Link