WordPress Playground CLI for Quick Testing

SkillCloud & infra

Use for quick local testing with WordPress Playground CLI. Spins up a disposable WordPress instance with the plugin mounted, no Docker needed. Ideal for worktrees, quick feature checks, and parallel testing on different branches.

Available today. Use it from your connected AI after setup.

Connect ahel once, and every AI you use reads what you have installed.

Then ask your AI: use the WordPress Playground CLI for Quick Testing skill

What this skill tells your AI

The instructions your AI receives, as published by bonny/wordpress-simple-history in .claude/skills/wp-playground/SKILL.md and read by ahel’s review.

Use @wp-playground/cli to spin up fast, disposable WordPress instances for testing. No Docker required — uses WebAssembly + SQLite.

When to Use

  • Worktrees: each worktree gets its own Playground instance on a unique port
  • Quick feature check: spin up a site to verify a change without touching the Docker dev environment
  • Parallel branch testing: multiple branches in separate browser tabs
  • UI review: fast visual check of a feature or fix

For thorough testing that needs MySQL or WP-CLI, use the Docker Compose setup instead.

Quick Start (current directory)

Before starting, ensure build assets exist — Playground mounts the directory as-is:

# Install dependencies if node_modules is missing (common in worktrees).
# npm ci, not npm install — install can rewrite package-lock.json.
[ -d node_modules ] || npm ci

# Build JS/CSS assets (required — Playground has no build step)
npm run build

Then start:

npm run playground:start

This runs npx @wp-playground/cli server with the plugin mounted and the blueprint applied.

With a Blueprint (recommended)

Use the project blueprint for a pre-configured environment:

npx @wp-playground/cli server \
  --mount=.:/wordpress/wp-content/plugins/simple-history \
  --blueprint=.claude/worktree-blueprint.json \
  --port=9400

The blueprint (.claude/worktree-blueprint.json) enables dev mode, activates the plugin, logs in automatically, and enables experimental features.

Multiple Instances (worktrees or branches)

Preferred: use scripts/parallel-dev.sh — it creates the worktree, installs/builds, picks a free port, starts Playground detached, and tracks state per worktree (see the worktree skill for full usage):

scripts/parallel-dev.sh up <slug> [--no-premium] [--premium=<path>]
scripts/parallel-dev.sh status
scripts/parallel-dev.sh down <slug> [--remove]

Manual approach: each instance needs a unique port. Find the next available one:

PORT=9400; while lsof -i :$PORT >/dev/null 2>&1; do PORT=$((PORT+1)); done; echo $PORT

Then start each instance:

# Worktree 1
cd .claude/worktrees/issue-42
npx @wp-playground/cli server --mount=.:/wordpress/wp-content/plugins/simple-history --port=9400

# Worktree 2
cd .claude/worktrees/issue-55
npx @wp-playground/cli server --mount=.:/wordpress/wp-content/plugins/simple-history --port=9401

Each gets its own browser tab: http://localhost:9400, http://localhost:9401, etc.

Useful Flags

FlagPurpose
--auto-mountAuto-detect plugin/theme and mount it
--mount=src:destManually mount a directory
--port=NNNNSet the server port
--wp=6.3Use a specific WordPress version
--php=7.4Use a specific PHP version
--blueprint=pathApply a blueprint JSON on startup
--loginAuto-login as admin

Limitations

  • SQLite only — not MySQL/MariaDB. Use Docker for database-specific testing.
  • No WP-CLI — use wp-env or Docker if you need CLI commands.
  • Ephemeral by default — state may not persist across restarts.

Deprecated: wp-now

@wp-now/wp-now is deprecated. Use @wp-playground/cli with --auto-mount instead — it provides the same auto-detection behavior.

See Also

  • Worktree skill — full worktree workflow including Playground setup
  • npm scripts: playground:start, playground:server

Signals

GitHub stars
317
Forks
74
Last commit
Sep 2026

ahel review

  • K1binfo
    installs-packages

Automated review, not a security audit. Ruleset v1+k2.

Advanced
Catalog kind
skill
Gateway key
wp-playground
Source
github.com/bonny/wordpress-simple-history