What is WP-CLI?
WP-CLI (WordPress - Command Line Interface) is a command line tool for WordPress. It allows you to manage WordPress installations via the command line without having to log in to WordPress in your browser. This is particularly useful if you have multiple WordPress websites or manage them as a webmaster. With WP-CLI, you can also install additional scripts to further automate WordPress.
WP-CLI is already pre-installed on all Hostpoint servers. To use WP-CLI, you need to connect to your web hosting via SSH. You can find out how to do this in our article on setting up an SSH connection. You can then execute commands via WP-CLI in your WordPress directory using the console.
Useful commands
| Command | Explanation |
|---|---|
| wp core version | Displays the currently installed WordPress version |
| wp core check-update | Checks if a WordPress update is available |
| wp core update | Updates the WordPress core to the latest version |
| wp plugin list | Lists all installed plugins including status (active/inactive) and version |
| wp plugin update --all | Updates all installed plugins to the latest version |
| wp plugin activate <slug> | Activates a specific plugin (replace with the plugin slug, e.g., contact-form-7) |
| wp plugin deactivate <slug> | Deactivates a specific plugin (replace with the plugin slug, e.g., contact-form-7) |
| wp theme list | Lists all installed themes and indicates the active theme |
| wp theme activate <slug> | Activates a different theme |
| wp option get home | Displays the currently configured URL of your WordPress website (home URL) |
| wp option update home <url> | Changes the currently configured URL of your WordPress website (home URL) |
| wp option update siteurl <url> | Changes the URL of your WordPress installation (backend) |
| wp user list | Lists all registered users |
| wp user update <user id> --user_pass=<password> | Sets a new password for a specific user (replace with the user ID and new password) |
| wp db export | Creates a database backup as an SQL file |
| wp cache flush | Clears the WordPress cache |
Further information on WP-CLI
- Available commands: https://developer.wordpress.org/cli/commands/
- Handbook: https://make.wordpress.org/cli/handbook/
For support requests please use this form instead.




