Activate a theme
activate_themeActivate a WordPress theme by specifying its stylesheet directory name. Immediately changes the live site's appearance for all visitors, requiring explicit confirmation before applying.
Instructions
Switch the site's active theme. This changes the entire front-end appearance immediately, and widget/menu assignments do not always carry across. Requires confirm: true. If you are iterating on a theme you are building, use the draft workflow and publish_draft_theme instead.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| confirm | No | Required — this changes the live site's appearance for every visitor. | |
| site_id | No | Which configured WordPress site to act on. Optional — with a single site configured it is used automatically; with several, the default site is used unless you name one. Run list_sites for valid ids. | |
| stylesheet | Yes | Theme directory name to activate. |