> For the complete documentation index, see [llms.txt](https://docs.konsist.lemonappdev.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.konsist.lemonappdev.com/help/compatibility.md).

# Compatibility

Konsist ecosystem compatibility

Konsist is compatible with all types of Kotlin projects including [Android](https://www.android.com/), [Spring](https://spring.io/), and [Kotlin Multiplatform](https://kotlinlang.org/docs/multiplatform.html) projects.

Konsist works with popular testing frameworks executing Kotlin code. Konsist has first-class support for [JUnit4](https://junit.org/junit4/), [JUnit5](https://junit.org/junit5/), and [Kotest](https://kotest.io/).

Konsist works with Kotest `5.x` and `6.x`. The `KoKotestExtension` (see [Kotest Support](/features/kotest-support.md)) requires Kotest `6.x`. With Kotest `5.x` pass the `testName` argument instead.

Konsist is compatible with popular build systems such as [Gradle](https://gradle.org/) and [Maven](https://maven.apache.org/).

`Java 11` is the minimum [Java](https://www.java.com/en) version required to run Konsist (Konsist `0.18.x` requires `Java 17`).

## Operating Systems

Konsist works on macOS, Linux and Windows:

* Path arguments (e.g. `scopeFromDirectory`, `scopeFromFile`, `residesInPath`, `withPath`) accept both `/` and `\` separators on all operating systems.
* `path`, `projectPath` and `location` use operating system separators (`\` on Windows, `/` on other operating systems). `moduleName` uses `/` separators on all operating systems (e.g. `feature/data`).
* File links in assertion failure messages use the `file:///` format with `/` separators, so they are clickable in the IntelliJ IDEA console on all operating systems.

Kotlin files are parsed regardless of the line endings (`LF`, `CRLF` or `CR`) and the UTF-8 BOM.

## Kotlin Compatibility

Konsist parses Kotlin code with its own Kotlin compiler (`kotlin-compiler-embeddable`), so the Kotlin version used by the project does not have to match the Kotlin version used by Konsist. Konsist is compiled with Kotlin API/language version `2.0` and requires `kotlin-stdlib` `2.0.21`+ (Konsist `0.17.x` is backwards compatible with Kotlin `1.8.x`).

| Project Kotlin version | Gradle (JVM, Spring) | Gradle (Android, AGP 8) | Gradle (Android, AGP 9) | Maven         |
| ---------------------- | -------------------- | ----------------------- | ----------------------- | ------------- |
| `1.8.x` and older      | ❌                    | ❌                       | -                       | ❌             |
| `1.9.x`                | ✅                    | ✅                       | -                       | ❌ (1)         |
| `2.0.x`                | ✅                    | ✅                       | -                       | ❌ (1)         |
| `2.1.x`                | ✅                    | ✅                       | -                       | ❌ (1)         |
| `2.2.x`                | ✅                    | ✅                       | ✅                       | ❌ (1)         |
| `2.3.x`                | ✅                    | ✅                       | ✅                       | ✅             |
| `2.4.x`                | ✅                    | ✅                       | ✅                       | ✅             |
| **Minimum**            | **`1.9`**            | **`1.9`**               | **`2.2.10`** (2)        | **`2.3`** (1) |

(1) Maven projects using Kotlin older than `2.3` require the `-Xskip-metadata-version-check` compiler argument (see [Maven: Module was compiled with an incompatible version of Kotlin](/help/known-issues/maven-module-was-compiled-with-an-incompatible-version-of-kotlin.md)).

(2) Minimum Kotlin version supported by the Android Gradle Plugin 9.

{% hint style="info" %}
Kotlin `1.9.x` projects may still fail to compile because of other dependencies requiring newer `kotlin-stdlib` (e.g. `de.mannodermaus.android-junit5` plugin `1.13`+). This is not related to Konsist.
{% endhint %}

## Kotlin Standard Library Compatibility

| `kotlin-stdlib`             | Gradle                                            | Maven                                                                          |
| --------------------------- | ------------------------------------------------- | ------------------------------------------------------------------------------ |
| Version required by Konsist | `2.0.21`                                          | `2.0.21`                                                                       |
| Version used by the project | The highest version (project version or `2.0.21`) | The version declared by the project (Maven nearest-wins dependency resolution) |
| Minimum version             | `2.0.21`                                          | `2.0.21`                                                                       |

Konsist does not upgrade `kotlin-stdlib` used by the project to the version of its own Kotlin compiler.

{% hint style="warning" %}
When a BOM (e.g. Spring Boot dependency management) downgrades `kotlin-compiler-embeddable` to the project Kotlin version, Konsist works, but can't parse Kotlin syntax newer than this version.
{% endhint %}

## Dependencies

Konsist depends on:

* `org.jetbrains.kotlinx:kotlinx-coroutines-core-jvm:1.9.0` (minimal coroutine usage makes Konsist compatible with newer coroutines versions)
* `org.jetbrains.kotlin:kotlin-compiler-embeddable:2.4.21` (without `kotlin-stdlib` dependency)
* `org.jetbrains.kotlin:kotlin-stdlib:2.0.21`

JUnit and Kotest are not Konsist dependencies. `KoJUnitExtension` and `KoKotestExtension` use the test framework already present in the project.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.konsist.lemonappdev.com/help/compatibility.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
