wp site update
Overview
Modify the properties or operational status of a subsite. This is used to change a site's public visibility, mark it as spam, or archive it.
Syntax
wp site update <id> [--spam=<value>] [--archived=<value>] [--mature=<value>] [--public=<value>]
Options
| Flag | Description |
|---|---|
ID | ID of the site to update |
--spam | 1 to mark as spam, 0 to unmark |
--archived | 1 to archive, 0 to unarchive |
--public | 1 for public, 0 for private |
Basic Usage
Archive a site
wp site update 3 --archived=1
Output:
Success: Site 3 updated.
Real-World Scenarios
Scenario 1: Managing problematic sites
# Silence a site without deleting it
wp site update 10 --spam=1
Scenario 2: Opening a private site to the public
wp site update 12 --public=1
Next Steps
wp site list— see the updated list.wp site delete— if archiving isn't enough.