Skip to content
SPECIFICTION
Get listed

Duplo vs phpcpd-next

Duplo

github.com

phpcpd-next

github.com

Side by side

FigureDuplophpcpd-next
Price fromFreeFree
Free planYesYes
Free trial——
Open source——
WindowsYes—
macOSYes—
LinuxYesYes
API—Yes
Self-hosted—Yes
Plans published11
Spec score · Code Clone Detection Tools7.9 (#5)7.4 (#14)
Spec score · Code Duplication Detection Tools7.9 (#5)7.4 (#9)
LicenseDuplo is free software under the GNU General Public License version 2 or, at the user's option, any later version, and is provided without warranty.The project states that phpcpd-next is licensed under MIT.
PurposeDuplo finds duplicated code blocks in large codebases.phpcpd-next is a token-based copy/paste detector for PHP 8.4+ and a successor to Sebastian Bergmann’s phpcpd.
ReportsDuplo can output results as JSON or XML, and its XML can be displayed in a browser using an included stylesheet.It provides console, PMD-CPD XML, JSON, and SARIF 2.1.0 output formats.
SupportThe maintainer asks users to open an issue for feedback, feature requests, and bug reports.The opened project page describes contribution guidance and a Contributor License Agreement; it does not state a paid support plan.

Plans

Duplo

  • DuploFree

Duplo pricing →

phpcpd-next

  • Open sourceFree

phpcpd-next pricing →

In their own words

Duplo

Duplo is a free tool for locating duplicated source-code blocks in large codebases. It has built-in language support for C/C++, Java, C#, VB, GCC assembly, Ada, Erlang, TypeScript and Swift, and can also scan arbitrary text files, including for duplicates within one file. For supported languages, it can filter comments, preprocessor directives and other syntax before checking for repeated code. Files can be provided through standard input or a separate file list. Duplo produces text reports as well as JSON and XML output. The project describes XML reports as usable in continuous integration tools such as GitHub Actions and TeamCity, and links to a GitHub Actions extension that can fail a build when duplicates are found. That extension has settings for minimum duplicate lines, minimum line length and maximum files reported. Prebuilt binaries are available for Alpine Linux, macOS and Windows; it can also be built from source. Duplo is free under GNU GPL version 2 or later, and is provided without warranty.

Visit github.com

phpcpd-next

phpcpd-next is a free, MIT-licensed, token-based detector for copied PHP code in repositories. It targets PHP 8.4 and later and succeeds Sebastian Bergmann’s phpcpd. The default run combines Rabin-Karp exact matching with TokenBag detection for reordered code. An opt-in unified engine detects exact, renamed, gapped and reordered clones, while optional orphan mode identifies unreferenced classes, interfaces, traits, enums and functions. Results can be printed to the console or written as PMD-CPD XML, JSON and SARIF 2.1.0. Meaningful exit codes, result caching and a per-file incremental index support continuous integration; clone findings return status 1. Documented integrations include PHPUnit, an in-process headless API, framework presets and SARIF upload to GitHub Code Scanning. Installation is available through Composer as a development dependency or global package, or from source. Requirements are PHP 8.4+, ext-dom and ext-mbstring, with zero Composer runtime dependencies. Advanced engines are described as research-grade and may produce more false positives than the default set.

Visit github.com