WordPress at a glance
Home Handbook WP-CLI Commands

wp super-admin

Lists, adds, or removes super admin users on a multisite installation.

Commands Description
Lists users with super admin capabilities.
Grants super admin privileges to one or more users.
Removes super admin privileges from one or more users.

Examples

# List user with super-admin capabilities
$ wp super-admin list
supervisor
administrator

# Grant super-admin privileges to the user.
$ wp super-admin add superadmin2
Success: Granted super-admin capabilities.

# Revoke super-admin privileges to the user.
$ wp super-admin remove superadmin2
Success: Revoked super-admin capabilities.

Source code of the commands


wp super-admin list

Lists users with super admin capabilities.

Usage

wp super-admin list [--format={format}]

You can specify global options and the following:

[--format={format}]

Render output in a particular format.
Default: list
Can be:

  • list
  • table
  • csv
  • json
  • count
  • yaml

Examples

# List user with super-admin capabilities
$ wp super-admin list
supervisor
administrator

wp super-admin add

Grants super admin privileges to one or more users.

Usage

wp super-admin add {user}...

You can specify global options and the following:

{user}...
One or more user IDs, user emails, or user logins.

Examples

$ wp super-admin add superadmin2
Success: Granted super-admin capabilities.

wp super-admin remove

Removes super admin privileges from one or more users.

Usage

wp super-admin remove {user}...

You can specify global options and the following:

{user}...
One or more user IDs, user emails, or user logins.

Examples

$ wp super-admin remove superadmin2
Success: Revoked super-admin capabilities.