WordPress Plugin Header Generator
Generate a clean WordPress plugin header with version, PHP and WordPress requirements, licensing, text domain, update URI and plugin dependencies.
Runs locally in your browserGenerator only. Choose version requirements from actual testing and review the header before shipping your plugin.
Build a valid WordPress plugin header without memorizing every field
The main PHP file of a WordPress plugin needs a specially formatted header so WordPress can identify the plugin and read its metadata. This generator creates that header from structured inputs and keeps optional fields out when you leave them blank.
What this generator supports
- Plugin Name, URI, description and version.
Requires at leastandRequires PHP.- Author and Author URI.
- GPL-compatible license and License URI fields.
- Text Domain and Domain Path.
Update URIfor plugins distributed outside WordPress.org.Requires Pluginsfor declared plugin dependencies.
Where the header belongs
Put the generated header in the plugin’s main PHP file. WordPress documentation says only one file in the plugin folder should contain the plugin header, and Plugin Name is the minimum required field.
Using Requires Plugins correctly
The Requires Plugins field accepts a comma-separated list of WordPress.org-formatted plugin slugs, not plugin file paths. WordPress core uses this metadata to help prevent activation when declared dependencies are unavailable. Dependency version constraints and plugin loading order are not handled by this field, so defensive runtime checks can still be necessary.
Requirements are metadata, not a compatibility test
Requires at least and Requires PHP tell WordPress the minimum versions you declare. Choose values from actual testing and the APIs your plugin uses rather than copying the defaults from this generator. For a separate pre-upgrade check, use the WordPress PHP Requirements Checker.
Update URI matters for private plugins
If a plugin is distributed outside WordPress.org, a unique Update URI can help prevent it from being accidentally overwritten by a similarly named directory plugin. Use a URI you control and review WordPress’s current update guidance before shipping.
Frequently asked questions
Does this create a complete plugin?
No. It generates the metadata header only. Your plugin still needs secure, maintainable PHP and any required assets.
Does WordPress read requirements from readme.txt?
For modern WordPress plugin requirements, the main PHP file is authoritative for fields such as Requires PHP and Requires at least. Keep the readme useful for users, but do not rely on it as the only place for runtime requirement metadata.
Can Requires Plugins specify a minimum dependency version?
No. The current dependency header declares plugin slugs, not version constraints. If your code requires a specific dependency API or version, validate that separately.
Related: After declaring PHP and WordPress requirements, use the PHP Requirements Checker. If the plugin schedules background work, the WordPress Cron Generator can help scaffold the scheduling code.
