Mobile apps · Tool

KSP

A Kotlin tool that lets libraries such as Room and Hilt generate code from annotations during the build, faster than the older kapt.

Android building blocks · Open source · updated

How it works

Many libraries work by reading annotations in your code and generating the repetitive parts: Room writes the database plumbing for a DAO, Hilt writes the dependency wiring. kapt did this by first generating Java stubs so that Java annotation processors could run, which was slow. KSP, made by Google, reads Kotlin code directly, and Google reports it can be up to twice as fast.

kapt is in maintenance mode, so projects move to KSP by swapping kapt(...) for ksp(...) in the Gradle file once every processor they use supports it. KSP also works in Kotlin Multiplatform, which kapt never did, and Room 3 requires it.

KSP pricing

Open source

Free (Apache 2.0).

Approximate, checked September 2026.What the other tools cost

More in Mobile apps

Android building blocks

All 34 Mobile apps terms

Crafted in the dark. Shipped to the world.

Tell us what you are building. You get a private project space with a proposal and a line-by-line quote within a day.