Loading...
Loading...
WordPress Playground for instant browser-based WordPress testing. Use for quick demos, plugin testing, or ephemeral development environments without Docker.
npx skill4agent add crazyswami/wordpress-dev-skills wp-playground# Start local Playground server
npx @wp-playground/cli server
# With custom blueprint
npx @wp-playground/cli server --blueprint=./blueprint.json
# Specify versions
npx @wp-playground/cli server --wp=6.8 --php=8.3{
"$schema": "https://playground.wordpress.net/blueprint-schema.json",
"landingPage": "/wp-admin/",
"login": true,
"preferredVersions": {
"php": "8.3",
"wp": "latest"
},
"phpExtensionBundles": ["kitchen-sink"],
"features": {
"networking": true
},
"steps": []
}| Step | Purpose | Example |
|---|---|---|
| Install plugin from wp.org | |
| Install theme from wp.org | |
| Update wp_options | |
| Login as user | |
| Execute PHP code | |
| Run WP-CLI command | |
| Create/modify file | |
| Create directory | |
{
"$schema": "https://playground.wordpress.net/blueprint-schema.json",
"landingPage": "/wp-admin/",
"login": true,
"preferredVersions": {
"php": "8.3",
"wp": "latest"
},
"steps": [
{
"step": "installPlugin",
"pluginData": { "resource": "wordpress.org/plugins", "slug": "admin-site-enhancements" },
"options": { "activate": true }
},
{
"step": "installPlugin",
"pluginData": { "resource": "wordpress.org/plugins", "slug": "branda-white-labeling" },
"options": { "activate": true }
},
{
"step": "installPlugin",
"pluginData": { "resource": "wordpress.org/plugins", "slug": "wordpress-seo" },
"options": { "activate": true }
},
{
"step": "installPlugin",
"pluginData": { "resource": "wordpress.org/plugins", "slug": "instant-images" },
"options": { "activate": true }
},
{
"step": "setSiteOptions",
"options": {
"blogname": "Development Site",
"blogdescription": "WordPress Playground Environment",
"permalink_structure": "/%postname%/"
}
}
]
}{
"$schema": "https://playground.wordpress.net/blueprint-schema.json",
"landingPage": "/wp-admin/admin.php?page=wc-admin",
"login": true,
"preferredVersions": {
"php": "8.3",
"wp": "latest"
},
"steps": [
{
"step": "installPlugin",
"pluginData": { "resource": "wordpress.org/plugins", "slug": "woocommerce" },
"options": { "activate": true }
},
{
"step": "installTheme",
"themeData": { "resource": "wordpress.org/themes", "slug": "storefront" },
"options": { "activate": true }
}
]
}{
"$schema": "https://playground.wordpress.net/blueprint-schema.json",
"landingPage": "/",
"login": true,
"preferredVersions": {
"php": "8.3",
"wp": "latest"
},
"steps": [
{
"step": "installTheme",
"themeData": { "resource": "wordpress.org/themes", "slug": "developer" },
"options": { "activate": true }
},
{
"step": "installPlugin",
"pluginData": { "resource": "wordpress.org/plugins", "slug": "theme-check" },
"options": { "activate": true }
},
{
"step": "installPlugin",
"pluginData": { "resource": "wordpress.org/plugins", "slug": "developer" },
"options": { "activate": true }
}
]
}# Start with defaults
npx @wp-playground/cli server
# Custom port
npx @wp-playground/cli server --port=3000
# Specific WordPress version
npx @wp-playground/cli server --wp=6.7
# PHP version
npx @wp-playground/cli server --php=8.2
# Blueprint file
npx @wp-playground/cli server --blueprint=./my-blueprint.json
# Auto-mount current directory as plugin/theme
npx @wp-playground/cli server --auto-mount# Build ZIP snapshot from blueprint
npx @wp-playground/cli build-snapshot blueprint.json output.zip
# Use snapshot
npx @wp-playground/cli server --mount=./output.zip# Mount local plugin
npx @wp-playground/cli server \
--mount=/local/plugin:/var/www/html/wp-content/plugins/my-plugin
# Mount local theme
npx @wp-playground/cli server \
--mount=/local/theme:/var/www/html/wp-content/themes/my-theme# Install plugin
https://playground.wordpress.net/?plugin=woocommerce
# Install multiple plugins
https://playground.wordpress.net/?plugin=woocommerce&plugin=yoast-seo
# Install theme
https://playground.wordpress.net/?theme=astra
# Specific versions
https://playground.wordpress.net/?wp=6.7&php=8.3
# Go to admin
https://playground.wordpress.net/?mode=seamless&login=yes
# Use blueprint URL
https://playground.wordpress.net/?blueprint-url=https://example.com/blueprint.jsonimport { startPlayground } from '@wp-playground/client';
const playground = await startPlayground({
iframe: document.getElementById('wp-frame'),
blueprint: {
landingPage: '/wp-admin/',
login: true,
steps: [
{
step: 'installPlugin',
pluginData: { resource: 'wordpress.org/plugins', slug: 'woocommerce' },
options: { activate: true }
}
]
}
});
// Run WP-CLI commands
const result = await playground.run({
step: 'wp-cli',
command: 'plugin list'
});
console.log(result);npx @wp-playground/cli server --blueprint=./test-blueprint.json--auto-mount| Feature | Playground | Docker |
|---|---|---|
| Setup time | Instant | 2-5 min |
| Persistence | Temporary | Permanent |
| Performance | Slower | Faster |
| Server required | No | Yes |
| Use case | Testing, demos | Development |
| Networking | Limited | Full |
| No | Yes (with SMTP) | |
| WP-CLI | Limited | Full |
~/.claude/skills/wp-playground/blueprints/base.jsonwoocommerce.jsontheme-dev.json