An anti-bikeshedding Kotlin linter with built-in formatter
6,742
stars
2,728
commits
Kotlin
primary language
Sep 9, 2026
updated
Kotlin linter in spirit of standard/standard (JavaScript) and gofmt (Go).
.editorconfig supportplain, json, html and checkstyleFollow steps below for a quick start with latest ktlint release.
Step 1: Install with brew
brew install ktlint
See download and verification from GitHub for native executables and the executable JAR, or other package managers for alternative ways of installing ktlint. Or, use one of the integrations like maven and gradle plugins.
Step 2: Lint and format your code
All files with extension .kt and .kts in the current directory and below will be scanned. Problems will be fixed automatically when possible.
ktlint --format
# or
ktlint -F
See cli usage for a more extensive description on using ktlint.
This project is no longer affiliated with Pinterest and is not affiliated with nor endorsed by JetBrains.
All code, unless specified otherwise, is licensed under the MIT license.
Copyright (c) 2026 Ktlint
Copyright (c) 2019-2026 Pinterest, Inc.
Copyright (c) 2016-2019 Stanley Shyiko.
(top 30 of 169)
Kotlin
99.9%
An anti-bikeshedding Kotlin linter with built-in formatter
6,742
stars
2,728
commits
Kotlin
primary language
Sep 9, 2026
updated
Kotlin linter in spirit of standard/standard (JavaScript) and gofmt (Go).
.editorconfig supportplain, json, html and checkstyleFollow steps below for a quick start with latest ktlint release.
Step 1: Install with brew
brew install ktlint
See download and verification from GitHub for native executables and the executable JAR, or other package managers for alternative ways of installing ktlint. Or, use one of the integrations like maven and gradle plugins.
Step 2: Lint and format your code
All files with extension .kt and .kts in the current directory and below will be scanned. Problems will be fixed automatically when possible.
ktlint --format
# or
ktlint -F
See cli usage for a more extensive description on using ktlint.
This project is no longer affiliated with Pinterest and is not affiliated with nor endorsed by JetBrains.
All code, unless specified otherwise, is licensed under the MIT license.
Copyright (c) 2026 Ktlint
Copyright (c) 2019-2026 Pinterest, Inc.
Copyright (c) 2016-2019 Stanley Shyiko.
(top 30 of 169)
Kotlin
99.9%