After the original proposal for a WordPress plugin check a little over two years ago, the Plugin Check plugin (or PCP for short) has become a reality. It saw its first stable release earlier this year and has since been used by hundreds of developers. This post provides more context about Plugin Check and why you should start using it.
Plugin Check is a tool for testing whether your plugin meets the required standards for the WordPress.org plugin directory. With this plugin you will be able to run most of the checks used for new submissions, and check if your plugin meets the requirements. The plugins team is currently working on making it an integral part of the review process. If you are considering submitting a new plugin to the plugin directory, run these checks yourself beforehand to save time later on.
But there is more! In addition to things relevant for the review process, the tool flags violations or concerns around plugin development best practices, from basic requirements like correct usage of internationalization functions to accessibility, performance, and security best practices. It does so using both static checks using PHP_CodeSniffer and dynamic checks, where it actually activates your plugin to test it “live”.
Because of this, PCP is useful even beyond the initial plugin submission, which is why it’s recommended to make it a part of your development workflow. This shortens your feedback loop as you can immediately address potential bugs as they come up, before they affect your users. To achieve this, simply install the plugin on a local environment and regularly run it against your plugin. The checks can be run either via WordPress admin or WP-CLI.

For even more peace of mind you can continuously monitor your plugin using a dedicated GitHub action. It automatically runs Plugin Check against your plugin for every commit or PR, and posts all results as annotations on your source files so you know exactly where to look for resolving any errors or warnings.

Plugin Check is not a replacement for the manual review process, but it will help you speed up the process of getting your plugin approved for the WordPress.org plugin repository, and it will also help you avoid some common mistakes. Even if you do not intend to host your plugin in the WordPress.org directory, you are encouraged to use it so that your plugin follows the base requirements and best practices for WordPress plugins. Keep in mind that automated tools like this aren’t perfect, so there may occasionally be false positives.
All development for this plugin is handled via GitHub, and any bug reports or feature requests should be reported there. The GitHub Action is maintained in its own repository.
Download the Plugin Check plugin or install the Plugin Check GitHub Action today to get started.
Written and reviewed by swissspidy, flixos90, davidperez