VPS Malaysia Blog

General

WP-CLI Hacks: Manage WordPress Like a Pro

WP-CLI lets administrators manage WordPress from the terminal instead of the dashboard. It speeds up plugin, theme, post, database, backup and automation tasks, especially across many sites.

3D command-line console controlling WordPress-style plugins themes posts database and backup modules
CLIManage WordPress without opening a browser
BulkUpdate, install and audit many items quickly
ScriptAutomate repeatable WordPress operations

WordPress Command Line

What this guide covers.

3D command-line console controlling WordPress-style plugins themes posts database and backup modulesCLI Control

WP-CLI lets administrators manage WordPress from the terminal instead of the dashboard. It speeds up plugin, theme, post, database, backup and automation tasks, especially across many sites.

WP-CLI is a command-line interface for WordPress that can perform many dashboard tasks faster.

It is useful when the dashboard is broken because commands can disable plugins, reset users or repair database issues.

Advanced users can script full site setup, content generation, updates, backups and search-replace workflows.

Redesigned Guide

Visual decision path.

What WP-CLI Does

WP-CLI is like a remote control for WordPress. It lets you manage the site with commands for core, plugins, themes, users, posts and database tasks.

Update WordPress coreInstall and activate pluginsManage themesCreate or delete postsRun database commands

Why Pros Use It

The command line reduces clicking, supports bulk operations and can recover sites when the admin dashboard is unavailable.

Save time across many sitesDisable broken pluginsAvoid extra plugins for bulk tasksGenerate dummy contentAutomate site setup scripts

Install Flow

Installation usually downloads the Phar file, verifies it, makes it executable and moves it into a command path.

Download wp-cli.pharTest the PharMake it executableMove to PATHVerify with wp --info

Daily Operations

Common WP-CLI workflows cover plugins, themes, content, database backup, restore, search-replace and cleanup.

List plugins and themesInstall, activate, deactivate and deleteCreate posts and import contentExport and restore databaseSearch-replace URLs safely

Quick Reference

WP-CLI Command Map

Plugins

List, search, install, activate, deactivate, update and delete plugins.

Themes

Install, activate, update and inspect themes from the terminal.

Content

Create posts, import files, generate dummy content and clean revisions.

Database

Run queries, export backups, import restores and perform search-replace.

Recovery

Disable broken plugins or reset access when wp-admin is unavailable.

Automation

Combine commands into scripts for repeatable WordPress site setup.

WP-CLI turns WordPress administration into repeatable operations. On a VPS or managed WordPress hosting environment with shell access, it becomes one of the fastest ways to manage sites professionally.

Explore VPS Malaysia Services