Iterate on your Compose UIs faster, and let your creativity run free when building multiplatform user interfaces.
Make changes to your UI code in a Compose Multiplatform application and see the results in real time.
No restarts required.
Compose Hot Reload runs your application on the JetBrains Runtime
and intelligently reloads your code whenever it is changed.
Getting Started
Requirements
A Compose Multiplatform project with a desktop target (see FAQ)
Kotlin 2.1.20 or higher
Apply the Gradle plugin to your project
Add the org.jetbrains.compose.hot-reload Gradle plugin to your build script:
plugins {
kotlin("multiplatform") version "2.1.20"// <- Use Kotlin 2.1.20 or higher!
kotlin("plugin.compose") version "2.1.20"// <- Use Compose Compiler Plugin 2.1.20 or higher!
id("org.jetbrains.compose")
id("org.jetbrains.compose.hot-reload") version "1.0.0-alpha10"// <- add this additionally
}
Run the application
Multiplatform + IntelliJ
Using Kotlin Multiplatform and IntelliJ, launching your app is as simple as pressing 'run' on your main function:
Gradle Tasks
Run Tasks
The plugin will create the following tasks to launch the application in 'hot reload mode':
:jvmRunHot: Multiplatform, async alternative (jvmRunHotAsync)
:runHot: Kotlin/JVM, async alternative (runHotAsync)
Arguments
--mainClass <Main Class FQN>:
The main class to run. Example: --mainClass com.example.MainKt
Note: This optimization is not required, but will lead to a better user experience.
It is expected that the feature will be enabled by default in future versions of the compiler.
Set up automatic provisioning of the JetBrains Runtime (JBR) via Gradle
[!IMPORTANT]
To use the full functionality of Compose Hot Reload, your project must run on the JetBrains Runtime (JBR, an OpenJDK fork that supports enhanced class redefinition).
Gradle can perform the download and setup for the JBR automatically for you via Gradle Toolchains.
Add the following to your settings.gradle.kts:
plugins {
id("org.gradle.toolchains.foojay-resolver-convention") version "0.10.0"
}
The Compose Hot Reload Gradle plugin will then use this resolver to automatically provision a compatible JDK.
FAQ
My multiplatform project doesn't have a Desktop target. Can I use Compose Hot Reload?
To use Compose Hot Reload, you'll have to add a module to your project that does configure a desktop target. It's worth noting that you will only be able to hot-reload code that can be run on the desktop JVM target. A possible setup might be the following:
A ui-components module that specifies platform-agnostic UI components.
A gallery module with a configured desktop target and Compose Hot Reload.
I am developing an Android application and am not using Kotlin Multiplatform. Can I use Compose Hot Reload?
Compose Hot Reload is designed to work with Compose Multiplatform. If you'd like to use Compose Hot Reload with an Android-only project, you will have to:
Switch from the Jetpack Compose plugin to the Compose Multiplatform plugin.
Add a separate Gradle module and configure the desktop target according to the instructions above.
My project is a desktop-only app with Compose Multiplatform. Can I use Compose Hot Reload?
Yes! However, please note that you can't start the application via the run button in the gutter (CMP-3123). Instead, use the custom Gradle task as described above.
Using 'dev' builds
The project publishes dev builds. To obtain the 'dev' Compose Hot Reload artifacts, first add the firework Maven repository:
In your projects' settings.gradle.kts, add the following:
We found that org.jetbrains.compose.hot-reload:runtime-api-iossimulatorarm64 demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.It has 0 open source maintainers collaborating on the project.
Package last updated on 15 May 2025
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
TC39 advances 9 JavaScript proposals, including Array.fromAsync, Error.isError, and Explicit Resource Management, which are now headed into the ECMAScript spec.