WordPress Plugin Boilerplate Generator A modern starter in one zip.
Generate your plugin
Your plugin
gallery-boost.zip · 13 files
/.git
/.github
/node_modules
/vendor
.distignore
.gitignore
composer.json
composer.lock
phpcs.xml.dist
package.json
package-lock.json
Built in your browser. Upload the zip in Plugins > Add New > Upload Plugin, or unzip it into wp-content/plugins. Run composer install first if you picked composer.json.
How it works
- 1
Name it
The name sets the folder, slug, text domain, namespace and prefix.
- 2
Pick the parts
Only what you need: settings, block, REST, a post type.
- 3
Look through it
Browse every file before you download.
- 4
Install the zip
Upload it in Plugins > Add New, or unzip into wp-content/plugins, and activate.
What you get
Every file is small and commented, so you can read the whole plugin in a few minutes and know where your code goes.
Namespaces and PSR-4
Classes live in src/ under your own namespace, loaded by a tiny autoloader. No class name collisions with other plugins.
Settings page done right
Settings API with register_setting, a sanitize callback, escaped output and a capability check. The nonce comes from settings_fields().
Gutenberg block without a build
block.json (API version 3), an index.asset.php with the script dependencies and plain JavaScript you can later move to @wordpress/scripts.
REST endpoint with a permission check
A route under /wp-json/your-slug/v1 with a real permission_callback and validated, sanitized arguments.
Clean activation and uninstall
Default options on activation, scheduled events cleared on deactivation, and every option removed on uninstall, across a multisite network.
Coding standards config
phpcs.xml.dist with the WordPress ruleset, your text domain and your prefixes, plus .distignore to keep dev files out of releases.
Before you submit to WordPress.org
The boilerplate gets the structure right. These are the steps that usually decide how fast the review goes.
Run Plugin Check
Install the official Plugin Check plugin on a test site and fix every error it reports.
Escape late, sanitize early
Escape every value at the moment you print it, sanitize every value the moment you receive it.
No remote code or tracking
Do not load scripts from other servers or send data home without asking the user first.
A real readme.txt
A clear name, short description, tags and FAQ. The readme generator checks it for you.
Want it built and published for you?
We build WordPress plugins, get them through the WordPress.org review and keep them updated. Our own plugins there have 4,000+ active installs.
Talk about your pluginWhat would your plugin cost to build?
Pick the type, size and features and get a price range, a timeline and the yearly support cost in about a minute.
Estimate my pluginFAQ
More free tools
WordPress Readme Generator & Validator
Write or check your plugin readme.txt with a live preview and an SEO score based on how WordPress.org search ranks plugins.
Open toolWordPress Plugin Search Rank Checker
See where your plugin ranks in WordPress.org search for any keyword, and why the top 10 rank above you.
Open toolWordPress Plugin Stats & Comparison
Downloads chart, active installs, ratings and support for any WordPress.org plugin, with a side by side comparison.
Open toolWordPress Plugin Name Checker
Check a plugin name against the WordPress.org rules and see whether its slug is still free.
Open toolWordPress Plugin Header Generator
Generate the main plugin file header with every field checked against the WordPress.org rules.
Open toolWordPress Plugin Banner & Icon Generator
Turn one image (or your plugin name) into the four banner and icon files WordPress.org needs, named right.
Open tool