Monthly WP-CLI Maintenance Round

1–2 minutes

Goal

Entry-level monthly pass on a business WordPress site: inspect updates, export the database, update core and plugins, remove a risky File Manager plugin, lock wp-admin installs, flush cache.

Monthly WP-CLI Maintenance Round

Steps

1. Show which WordPress core version is installed

Show which WordPress core version is installed

Bash
wp core version

2. Check if WordPress core has an available update

Check if WordPress core has an available update

Bash
wp core check-update

3. List only plugins that have an update available

List only plugins that have an update available

Bash
wp plugin list --update=available

4. Export the database to a backup file before updates

Export the database to a backup file before updates

Bash
wp db export pre-update.sql

5. Update WordPress core (minor path is fine here)

Update WordPress core (minor path is fine here)

Bash
wp core update

6. Run the database schema update for the new core

Run the database schema update for the new core

Bash
wp core update-db

7. Update all plugins that have available updates

Update all plugins that have available updates

Bash
wp plugin update --all

8. Confirm no plugin updates are left

Confirm no plugin updates are left

Bash
wp plugin list --update=available

9. Delete the wp-file-manager plugin from the site

Delete the wp-file-manager plugin from the site

Bash
wp plugin delete wp-file-manager

10. Set DISALLOW_FILE_MODS so wp-admin cannot install or update plugins/themes

Set DISALLOW_FILE_MODS so wp-admin cannot install or update plugins/themes

Bash
wp config set DISALLOW_FILE_MODS true --raw --type=constant

11. Flush the WordPress object cache

Flush the WordPress object cache

Bash
wp cache flush

Practice Cases

Real workflows built with WP-CLI commands — not isolated examples, but full sequences that solve actual problems.