Lombok - Java JDK compatibility matrix
We really like Lombok, and we use it in many of our projects (probably all of them).
We regularly run into issues when we want to upgrade our JDK version and Lombok sometimes lags behind new JDK releases.
Lombok and JDK compatibility matrix
The table below tracks the minimum Lombok version required for recent JDK releases. Notably, the Lombok team achieved a major milestone with JDK 25, releasing a compatible version before the General Availability (GA) date.
| JDK | JDK Date | Lombok | Lombok release date |
|---|---|---|---|
| 25 Current LTS | 2025-09-16 | v1.18.40 | 2025-09-04 |
| 24 | 2025-03-18 | v1.18.38 | 2025-03-31 |
| 23 | 2024-09-17 | v1.18.36 | 2024-11-25 |
| 22 | 2024-03-19 | v1.18.32 | 2024-03-24 |
| 21 LTS | 2023-09-19 | v1.18.32 | 2024-03-24 |
| 20 | 2023-03-21 | v1.18.28 | 2024-05-23 |
You can find the release notes of Lombok here:
https://github.com/projectlombok/lombok/blob/master/doc/changelog.markdown
Should you use Lombok or avoid it? Is Lombok a hero or a villain in the JDK world?
If you want to deep dive into the topic, you can read the following article:
Lombok: The Batman of the JRE that saved Java from Boilerplate
The JDK 23+ Breaking Change: Annotation Processing
Even when Lombok keeps up with the latest JDK, compilation errors can occur due to JDK 23+ changes in annotation processing.
Starting with JDK 23, javac no longer runs annotation processors by default.
As of JDK 23, annotation processing is only run with some explicit configuration of annotation processing or with an explicit request to run annotation processing on the javac command line. This is a change in behavior from the existing default of looking to run annotation processing by searching the class path for processors without any explicit annotation processing related options needing to be present.
You must explicitly enable annotation processing in the Maven Compiler Plugin:
You can find the details of the problems and the possible fixes here: https://marmo.dev/lombok-java-23
FAQ
Is Lombok compatible with JDK 25?
Yes. Use version 1.18.40 or higher.
Is Lombok compatible with JDK 23?
Yes, there is a breaking change in the JDK; you need to update your Maven Compiler Plugin to use the full annotation processing strategy.
Why does my build fail on JDK 23 with cannot find symbol?
The JDK 23 compiler defaults to -proc:none and no longer runs annotation processors by default.
When using Maven, you must explicitly enable annotation processing via the Maven Compiler Plugin, otherwise Lombok annotations will not be processed and the build will fail with cannot find symbol.
See the full explanation and configuration examples here: https://marmo.dev/lombok-java-23
Is Lombok part of the official JDK?
No. It is a third-party library that uses internal APIs. This is why it is often sensitive to JDK internal changes.