Remove Java from your PC if no program you use needs it, and update it if something does. Java in the browser is gone, so the old "Java makes my PC unsafe" advice no longer applies on its own, but an unused and outdated runtime is still software you have to patch.
This guide is aimed at Windows PCs, where most people meet the question, with notes for macOS and Linux. It shows how to find out whether Java is used, how to uninstall it cleanly and what to install if you still need it.
Java is installed because some program asked for it. Games such as Minecraft Java Edition, developer tools like Eclipse, NetBeans or Android Studio, and business software (older accounting, banking or printing clients) are the common reasons. Some installers also drop a runtime for you without much warning.
The Java you see in the Windows installed apps list is a runtime (JRE) or a development kit (JDK). It is separate from JavaScript, which runs in every browser and cannot be removed.
The big risk was the browser plugin and Java applets. That route ended: Chrome removed support for the plugin interface in 2015, Firefox in 2017, and Java removed Web Start in Java 11 and has been removing the Applet API. A web page cannot start a JVM on your PC now.
What remains:
So the safe position is: no Java you do not need, and current Java for the Java software you do use.
Check in this order.
java -version. If it reports "not recognized", there is no Java on the PATH.A reliable test is to uninstall Java and see what breaks. A program that needs Java will say so when it starts, and you can reinstall it. Many modern apps ship their own private runtime inside their folder, so they keep working.
java -version again to confirm it reports that Java is not recognised.JAVA_HOME yourself, remove it under System Properties, Environment Variables.| Platform | Removal route |
|---|---|
| Windows | Installed apps, Uninstall |
| macOS | Delete the JDK from /Library/Java/JavaVirtualMachines, or brew uninstall |
| Linux | Remove the package with your package manager, for example sudo apt remove openjdk-21-jre |
Leave program folders alone: delete only through the uninstaller so registry entries are cleaned.
Install one currently supported long-term support (LTS) release rather than several old ones. As of November 2026 the LTS releases are 8, 11, 17, 21 and 25, with 25 the newest. Use the one your software documents: new development works well on 21 or 25, while some older programs require 8 or 11.
Free, regularly patched builds come from Eclipse Temurin, Amazon Corretto, Microsoft Build of OpenJDK and others. Use the vendor installer, enable its option to set JAVA_HOME and update the PATH only if you work from the command line, and check for updates every quarter, when Oracle-aligned security patches ship.
No. Websites use JavaScript, not Java, and browsers no longer support Java plugins. Removing Java does not change how pages load.
Yes, they install side by side. Only the one first on your PATH answers java -version, and each program may point at its own. Remove versions you do not use.
Read the documentation of the program that needs it. If nothing specifies a version, pick the newest LTS, currently Java 25.
The official launcher for Minecraft Java Edition bundles its own runtime, so a system-wide Java is usually not required. Mods and servers may need a specific one.
Test whether anything depends on Java with java -version and a look at your installed apps. If nothing does, uninstall it from Settings. If something does, keep one supported LTS release and update it regularly.