IntelliJ IDEA Gradle Sync Failed

Share
Workaround available Windows, macOS, Linux Updated November 13, 2026Based on 4 user reportsHow we research

Quick answer

Gradle sync failures are most often a JDK mismatch between the Gradle JVM and the Gradle version. Set the Gradle JVM explicitly and reload.

Most likely fix: Set the Gradle JVM

How to fix it

Try these in order — the most common fix is first.

  1. 1. Set the Gradle JVM

    1. Open Settings | Build, Execution, Deployment | Build Tools | Gradle
    2. Choose a JDK in the Gradle JVM field that your Gradle version supports
    3. Click Apply and Reload All Gradle Projects
    Did this fix it?
  2. 2. Check how the JVM is chosen

    1. IntelliJ checks org.gradle.java.home in gradle.properties first, then JAVA_HOME, then a suitable JDK; remove conflicting values
    Did this fix it?
  3. 3. Use the wrapper

    1. Run ./gradlew build in a terminal to confirm the build works outside the IDE
    Did this fix it?
  4. 4. Clear caches

    1. Use File | Invalidate Caches, then reload Gradle; if needed delete the project .gradle folder
    Did this fix it?

Symptoms

Build output shows 'Gradle sync failed', unsupported class file major version, or the project model is empty.

Why it happens

  • Gradle JVM too new or too old for the project's Gradle version
  • JAVA_HOME or org.gradle.java.home pointing somewhere unexpected
  • Network or proxy blocking Gradle downloads
  • Corrupted Gradle caches
  • Wrapper version incompatible with the plugin

This guide also covers

  • intellij gradle sync failed
  • intellij gradle jvm
  • unsupported class file major version intellij
  • intellij gradle build failed

Still not working?

If JetBrains IntelliJ keeps failing, you're not alone. See every JetBrains IntelliJ problem users report or the alternatives people switch to.

Have an app idea? Our small team builds any software: web and mobile apps, games, desktop, AI tools. Price agreed together.

Talk to us
Fixed it? Share this guide

The same problem in other apps

All sync failures guides →

Other JetBrains IntelliJ errors

All 12 JetBrains IntelliJ errors and fixes →