detekt
What it is
detekt is a static analyzer for Kotlin that identifies code smells. It supports Android, JVM, JS, Native, and Multiplatform projects, and runs on Linux, macOS, and Windows. Users can configure rule sets, establish baselines for existing findings, and suppress findings with @Suppress annotations. Output options include HTML, Markdown, SARIF, Checkstyle XML, and custom reports; complexity reports can show lines of code, cyclomatic complexity, and code smell counts. The project provides a Gradle plugin and documents use with Gradle, Maven, and Bazel. Its Gradle plugin requires Gradle 6.8.3 or later. Developers can add custom rule sets through the RuleSetProvider and ServiceLoader pattern. The marketplace lists community rules, extensions, and plugins, including a GitLab Code Quality reporter and ktlint rule wrappers. CLI installation guidance covers Homebrew, Scoop, SDKMAN, and NixOS. detekt is free, with no commercial limits stated, and supports autofix, IDE use, and CI. Community discussion is available through Kotlin Slack and Stack Overflow.
For and against
For
- Free, with no commercial limits stated.
- Supports Android, JVM, JS, Native, and Multiplatform.
- Offers HTML, Markdown, SARIF, and other reports.
- Custom rule sets and autofix are supported.
- Build guidance covers Gradle, Maven, and Bazel.
Against
- The Gradle plugin requires Gradle 6.8.3 or higher.
- Security patches cover the current minor version; earlier versions are case by case.
The verdict
detekt combines configurable Kotlin code analysis with multiple report formats and build integrations. Check the Gradle version requirement if using its Gradle plugin.
Who it suits
detekt suits Kotlin developers who want configurable static analysis across supported project types. Its build integrations and CI support may also suit teams incorporating checks into build workflows.
Plans and prices
detekt
Open-source Kotlin static analysis tool; no commercial limits stated
Read 4 Oct 2026 · detekt.dev
On the record
- Build integrations
- The project provides a Gradle plugin and documents use with Gradle, Maven, and Bazel builds.detekt.dev · read 4 Oct 2026
- CLI downloads
- The CLI installation guide documents Homebrew on macOS, Scoop on Windows, SDKMAN on Unix-like systems, and NixOS installation.detekt.dev · read 4 Oct 2026
- Community integrations
- The project marketplace lists community-built rules, extensions, and plugins, including a GitLab Code Quality reporter and ktlint rule wrappers.detekt.dev · read 4 Oct 2026
- Community support
- The project site links to Kotlin Slack and Stack Overflow for community discussion.detekt.dev · read 4 Oct 2026
- Complexity reports
- detekt can report lines of code, cyclomatic complexity, and code smell counts.detekt.dev · read 4 Oct 2026
- Extensibility
- Developers can add custom rule sets using detekt's RuleSetProvider and ServiceLoader pattern.detekt.dev · read 4 Oct 2026
- Gradle requirement
- The Gradle plugin guide states that detekt requires Gradle 6.8.3 or higher.detekt.dev · read 4 Oct 2026
- Project types
- The site says detekt supports Android, JVM, JS, Native, and Multiplatform projects.detekt.dev · read 4 Oct 2026
- Purpose
- detekt is a static code analyzer for Kotlin that helps identify code smells.detekt.dev · read 4 Oct 2026
- Reports
- Supported report formats include HTML, Markdown, SARIF, Checkstyle XML, and custom reports.detekt.dev · read 4 Oct 2026
- Rules
- Users can configure rule sets, generate baselines for existing issues, and suppress findings with @Suppress annotations.detekt.dev · read 4 Oct 2026
- Security support
- The security policy says patches are applied up to the current minor version and earlier versions are considered case by case.github.com · read 4 Oct 2026
- Vulnerability reporting
- The security policy asks reporters to email [email protected] and says the team commits to respond within two weeks.github.com · read 4 Oct 2026