i have minecraft version 1.16.4 on my pc. OS is windows 10. today I wanted to get new major update. when i run the launcher i got the error that said "minecraft does not detect java". so i uninstalled minecraft and java. i installed them again. but now after update i get this java error:

   [E] Error: A JNI error has occurred, please check your installation and try again
   [E] Exception in thread "main" java.lang.UnsupportedClassVersionError: 
   net/minecraft/client/main/Main has been compiled by a more recent version of the Java 
   Runtime (class file version 60.0), this version of the Java Runtime only recognizes class 
   file versions up to 52.0

what should i do to fix this? (if any further information is needed please comment so i add them to my question)

minecraft launcher is ExtremeLauncher i have javaRE 8.291 and javaDK 16 installed on my pc.

  • 1
    If you're trying to get 1.17, Java 16 (JDK/JRE16) is required. Also you never stated what launcher you were using. The default launcher by mojang would have solved this issue for you since it bundles the java versions required. – Phoenix Jun 9 at 15:47
  • @Phoenix I don't know what version my launcher is but i will add it to my question when i get home. actually when i ran into first error the launcher redirected me to a website to download java. but it had problems while redirecting so i could not see what version it wanted. – BlackCrystal Jun 10 at 3:00
  • 1
    You are running the code with Java 8 (class version 52) but it requires Java 16 (class version 60). – greg-449 Jun 10 at 6:44

thanks to @Phoenix and @greg-449 for answering.

I searched a little bit and saw this video: "www.youtube.com/watch?v=kehS3GkHiFM"

it solved my problem. for anyone that may face this problem, actually you should change java address in your launcher to something like this> C:\Program Files\Java\jdk-16\bin\javaw.exe

brows your pc for right address before changing.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.