# Understanding \`java.lang.UnsupportedClassVersionError\`

**URL:** <https://community.sonarsource.com/t/understanding-java-lang-unsupportedclassversionerror/101562>\
**Category:** Guides\
**Tags:** scanner\
**Created:** [September 27, 2023, 3:06pm UTC](https://community.sonarsource.com/t/understanding-java-lang-unsupportedclassversionerror/101562 "2023-09-27T15:06:19Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [September 27, 2023, 3:06pm UTC](https://community.sonarsource.com/t/understanding-java-lang-unsupportedclassversionerror/101562/1 "2023-09-27T15:06:20Z")

</div>

`Error during SonarQube Scanner execution java.lang.UnsupportedClassVersionError: org/sonar/batch/bootstrapper/EnvironmentInformation has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0`

This error is Java’s painfully obscure way of saying

> The version of Java you’re trying to use is too old to run this program.

To get your current version of Java, go to a command line and run

```auto
java --version

```

To get the version of Java you should be using, check the docs for your product:

- [SonarQube Server](https://docs.sonarsource.com/sonarqube/latest/analyzing-source-code/scanner-environment/)
- [SonarQube Cloud](https://docs.sonarcloud.io/appendices/scanner-environment/)

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [December 12, 2023, 2:37pm UTC](https://community.sonarsource.com/t/understanding-java-lang-unsupportedclassversionerror/101562/2 "2023-12-12T14:37:19Z")

</div>

Split this topic on December 12, 2023, 2:37pm UTC

A post was split to a new topic: [UnsupportedClassVersionError even though default version is Java 17](https://community.sonarsource.com/t/unsupportedclassversionerror-even-though-default-version-is-java-17/105888)

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [December 12, 2023, 2:37pm UTC](https://community.sonarsource.com/t/understanding-java-lang-unsupportedclassversionerror/101562/3 "2023-12-12T14:37:29Z")

</div>

Closed on December 12, 2023, 2:37pm UTC


