Skip to main content

wp plugin install (Multisite Context)

Overview

Install plugins to your network filesystem and optionally enable them for all sites immediately.

Syntax

wp plugin install <plugin>... [--activate] [--activate-network]

Options (Multisite Specific)

FlagDescription
--activate-networkInstall and network-activate immediately
--activateInstall and activate ONLY for the root site (unless --url is provided)

Basic Usage

Install and enable for everyone

wp plugin install autoptimize --activate-network

Output:

Success: Installed 'autoptimize'.
Success: Network activated plugin 'autoptimize'.

Best Practices

  1. Always test networking — Some plugins are not "multisite compatible." Verify before network-activating.
  2. Filesystem is shared — Installing a plugin makes the files available to the whole network, regardless of activation.