# PHPMD

> PHP Mess Detector: finds bugs and code smells in PHP

Source: https://talira.ai/catalog/phpmd-5bvh074k
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Command-line tool
- Categories: [developer tools / linting](https://talira.ai/categories/developer-tools/linting), [languages / php](https://talira.ai/categories/languages/php)
- Licence: BSD-3-Clause[^1]
- Pricing: Free and open source[^1]
- Free tier: yes[^1]
- Backed by: [PHPMD project](https://talira.ai/orgs/phpmd-project.md)
- Creator: Manuel Pichler, founder of PHPMD and PHP Depend

PHPMD (PHP Mess Detector) scans PHP source code for likely bugs, suboptimal code, overcomplicated expressions and unused parameters, methods and properties, using a set of predefined, configurable rule sets. It is a spin-off of PHP Depend and aims to be PHP's equivalent of the Java tool PMD, working as a friendly front end to the metrics PHP Depend measures. You run it from the command line or in CI, installed with Composer.

## Links

- Website: https://phpmd.org/
- GitHub: https://github.com/phpmd/phpmd
- Docs: https://phpmd.org/documentation/index.html

## Problems it solves

- find unused code and overly complex methods in our PHP codebase
- a PHP linter for code smells to run in CI
- something like PMD for PHP

## Features

- rules for possible bugs, unused code and overcomplicated expressions
- configurable rule sets
- command line and CI use
- built on PHP Depend metrics

## Trust

Overall: 0.65 out of 1.
Signals: maintenance 0.91, adoption 0.68, momentum 0.35, community 0.90, backing 0.50, extensibility 0.00.

- last commit 20 days ago
- 46 commits in the last 90 days
- latest release 3.0.0 56 days ago
- 2.5k GitHub stars
- 178 contributors
- accepts sponsorship (Tidelift)
- backed by PHPMD project
- created by Manuel Pichler, founder of PHPMD and PHP Depend

## Alternatives

- [PHPStan](https://talira.ai/catalog/phpstan-5dffx9mn.md): PHP static analysis that finds bugs without running your code
- [PHPCompatibility](https://talira.ai/catalog/phpcompatibility-ptwv532y.md): PHP_CodeSniffer sniffs that check PHP code for cross-version compatibility
- [PHP_CodeSniffer](https://talira.ai/catalog/php-codesniffer-zrnhrrbz.md): Detect and fix coding standard violations in PHP
- [PHPLint](https://talira.ai/catalog/phplint-bpnr9ztv.md): Lint PHP files faster by running several lint processes at once
- [MegaLinter](https://talira.ai/catalog/megalinter-crbmmnk7.md): Linting suite that checks every language, format and config file in a repository
- [Slevomat Coding Standard](https://talira.ai/catalog/slevomat-coding-standard-dfdcdx7p.md): Extra PHP_CodeSniffer sniffs for safer, cleaner and consistently formatted PHP

## Sources

[^1]: https://github.com/phpmd/phpmd/blob/3.x/LICENSE (checked 27 Nov 2026)
