IntelliJ Platform Plugin SDK Help

IntelliJ IDEA Plugin Development

IntelliJ IDEA Plugin Setup

Gradle Build Script

Define a dependency using intellijIdea(), see Versions link on top of this page for all available versions. See Local IntelliJ Platform IDE Instance for using a local installation.

Minimum build.gradle.kts setup:

repositories { mavenCentral() intellijPlatform { defaultRepositories() } } dependencies { intellijPlatform { intellijIdea("<versionNumber>") } }

The configuration of IntelliJ IDEA plugin projects follows the methods described in Configuring Plugin Projects using the IntelliJ IDEA Product Attribute.

gradle-intellij-plugin Attribute

Attribute Value

intellij.type

IU for IntelliJ IDEA

intellij.version

IDE version, e.g. 2022.2

Available API

See IntelliJ Platform Plugins Extension Point and Listener List for API from bundled plugins.

Product-Specific APIs in IntelliJ IDEA

The following pages describe targeting APIs available in IntelliJ IDEA:

Java Plugin

Configure bundled Java plugin dependency with plugin ID com.intellij.java.

PSI Cookbook lists a number of common operations for working with Java PSI.

Depending on the exact functionality, a plugin can also target UAST – Unified Abstract Syntax Tree to support multiple JVM languages, including Java and Kotlin.

Java Test Framework

To use existing test base classes, add TestFrameworkType.Plugin.Java test-framework available from Plugin Test Frameworks.

Alternatively, specify com.jetbrains.intellij.java:java-test-framework:$VERSION$ as testImplementation dependency explicitly (see IntelliJ Platform Artifacts Repositories).

Kotlin Plugin

Configure the bundled Kotlin plugin dependency with plugin ID org.jetbrains.kotlin.

Kotlin PSI explains the differences from the IntelliJ IDEA PSI and introduces the Analysis API as the new recommended way to work with Kotlin code.

See also UAST on how to support multiple JVM languages, including Kotlin.

Analysis API

Starting from IntelliJ IDEA 2025.1, K2 Kotlin mode is enabled by default. To ensure your plugin works with the newest versions of IntelliJ IDEA, you must migrate to the Analysis API and declare compatibility with the K2 compiler.

For migration details, see Migrating from K1.

For comprehensive information about the Analysis API, refer to Kotlin Analysis API Documentation.

Testing K1 (K2) mode

See Testing in K1 Locally.

Kotlin Code FAQ

How to shorten references?

11 February 2026