PMD PMD Source Code Analyzer Home Documentation Bugs About News Downloads Support Plugins PMD An extensible cross-language static code analyzer. Download Documentation Latest Version: 7.26.0 (29-June-2026) Release Notes | Source QuickStart See also Getting Started Linux MacOS Windows Windows (Chocolatey) $ cd $HOME $ wget https://github.com/pmd/pmd/releases/download/pmd_releases%2F7.26.0/pmd-dist-7.26.0-bin.zip $ unzip pmd-dist-7.26.0-bin.zip $ alias pmd="$HOME/pmd-bin-7.26.0/bin/pmd" $ pmd check -d /usr/src -R rulesets/java/quickstart.xml -f text $ cd $HOME $ curl -OL https://github.com/pmd/pmd/releases/download/pmd_releases%2F7.26.0/pmd-dist-7.26.0-bin.zip $ unzip pmd-dist-7.26.0-bin.zip $ alias pmd="$HOME/pmd-bin-7.26.0/bin/pmd" $ pmd check -d /usr/src -R rulesets/java/quickstart.xml -f text Download pmd-dist-7.26.0-bin.zip Extract the zip-archive, e.g. to C:\pmd-bin-7.26.0 Add folder C:\pmd-bin-7.26.0\bin to PATH, either Permanently: Using System Properties dialog Environment variables Append to PATH variable Temporarily, at command line: SET PATH=C:\pmd-bin-7.26.0\bin;%PATH% Execute at command line: pmd.bat check -d c:\src -R rulesets/java/quickstart.xml -f text Install Chocolatey, if you don't already have it! Install package PMD: choco install -y pmd Run from the command-line! pmd check -d c:\src -R rulesets/java/quickstart.xml -f text Checkout the existing rules for Java. About PMD PMD is an extensible multilanguage static code analyzer. It finds common programming flaws like unused variables, empty catch blocks, unnecessary object creation, and so forth. It's mainly concerned with Java and Apex, but supports 16 other languages. It comes with 400+ built-in rules. It can be extended with custom rules. It uses JavaCC and Antlr to parse source files into abstract syntax trees (AST) and runs rules against them to find violations. Rules can be written in Java or using a XPath query. Currently, PMD supports Java, JavaScript, Salesforce.com Apex and Visualforce, Kotlin, Swift, Modelica, PL/SQL, Apache Velocity, JSP, WSDL, Maven POM, HTML, XML and XSL. Scala is supported, but there are currently no Scala rules available. Additionally, it includes CPD, the copy-paste-detector. CPD finds duplicated code in Coco, C/C++, C#, CSS, Dart, Fortran, Gherkin, Go, Groovy, HTML, Java, JavaScript, JSP, Julia, Kotlin, Lua, Matlab, Modelica, Objective-C, Perl, PHP, PL/SQL, Python, Ruby, Rust, Salesforce.com Apex and Visualforce, Scala, Swift, T-SQL, Typescript, Apache Velocity, WSDL, XML and XSL. News 29 Jun 2026: PMD For Eclipse 7.26.0.v20260629-1513-r Released 29 Jun 2026: PMD 7.26.0 released 29 May 2026: PMD For Eclipse 7.25.0.v20260529-0757-r Released 29 May 2026: PMD 7.25.0 released 24 Apr 2026: PMD For Eclipse 7.24.0.v20260424-1056-r Released All news Downloads 7.26.0 (29-June-2026) Release Notes Download (Sourcecode, Documentation) Online Documentation 7.25.0 (29-May-2026) Release Notes Download (Sourcecode, Documentation) Online Documentation 7.24.0 (24-April-2026) Release Notes Download (Sourcecode, Documentation) Online Documentation 7.23.0 (27-March-2026) Release Notes Download (Sourcecode, Documentation) Online Documentation Support Need help? How do I? -- Ask a question on StackOverflow. I got this error, why? -- Ask a question on StackOverflow. I got this error and I'm sure it's a bug -- file an issue. I have an idea/request/question -- file an issue. I have a quick question -- ask on our Gitter chat. Where's your documentation? -- https://docs.pmd-code.org/latest/. Get Involved See How to contribute to PMD and How to build PMD. Our license: BSD-style. Source Code: Check it out on github Plugins PMD has been integrated into various tools as a plugin. This list is just a small extract. See IDE Plugins, CI Plugins and Other Integrations for a more complete list. Maven PMD plugin Gradle: The PMD Plugin Eclipse: eclipse-pmd Eclipse: pmd-eclipse-plugin IntelliJ: PMD X IntelliJ: PMD VS Code: Apex PMD VS Code: PMD for Java Home ⋅ Documentation ⋅ Bugs ⋅ About ⋅ News ⋅ Support ⋅ Downloads ⋅ Plugins Copyright © 2025 PMD. All Rights Reserved. Credits: Landing Page Theme, based on free to use, open source Bootstrap theme created by Start Bootstrap.