Skip to main content
All CollectionsModrinth AppWindows-specific questions
Java Virtual Machine Launcher errors
Java Virtual Machine Launcher errors

Invalid _JAVA_OPTIONS environment variable prevents Minecraft from launching.

Alex avatar
Written by Alex
Updated over 8 months ago

_JAVA_OPTIONS is an environment variable that provides options for the Java Virtual Machine (JVM) used to run Minecraft: Java Edition and other Java applications on your computer.

This variable is never used under normal circumstances. However, some programs register this variable in both the user and system environment variables. This can cause problems that can affect the performance of your game, make it impossible to adjust some Java settings such as the amount of memory allocated, or prevent the JVM from running altogether.

Screenshot of the Java Virtual Machine Launcher reporting an error ‘Error: Cound not create the Java Virtual Machine. Error: A fatal exception has occured. Program will exit’.

Removing _JAVA_OPTIONS variable

To determine if you are affected, and to resolve the issues caused by the presence of this variable, please follow these steps:

  1. Press Win+R to open a Run dialog.

  2. In the Open: field of the Run dialog, paste the following and press OK.

    powershell -Command "Start-Process -Verb RunAs -FilePath \"rundll32.exe\" -ArgumentList \"sysdm.cpl,EditEnvironmentVariables\"

  3. A command prompt may open, don't close it.

  4. If you see a User Account Control dialog, press Yes.

  5. You should see the Environment Variables settings window. In it, look for _JAVA_OPTIONS in both the User and System variable lists. When you find one, select it, and press Delete.

  6. When you're finished checking the lists, press OK.

  7. Sign out of your account and sign back in to apply the changes. To do this, right-click the ⊞ Start menu button or press Win+X. In the menu, select Shut down or sign outSign out.

  8. Verify that your issues are resolved.

Did this answer your question?