How to Uninstall Java on a Mac
Many Mac users don’t need Java on their computer, but if you happen to have Java installed and want to remove it from a Mac then you can uninstall Java and JRE with a little effort.
Uninstalling Java and JRE from the Mac is a little more complicated than installing it, as there is no dedicated uninstaller app or tool, and it’s not as simple as uninstalling other Mac apps since the components are split into different locations. Instead you’ll either turn to the command line, or dig around in the Finder and file system yourself to remove Java in Mac OS. We’ll show you how to remove java using both methods.
Note that by removing Java you will lose the ability to run any and all Java apps or Java dependent apps and applets, either individually, standalone, or via the web. You would obviously not want to uninstall Java if an app or web app you use requires Java. An alternative option would be to simply disable Java instead, which turns it off but does not remove it from the computer.
Uninstalling Java on the Mac
Removing Java from the Mac is a three step effort involving manually deleting various java related plug-ins and files found throughout macOS / Mac OS / Mac OS X, both in the system /Library folder and in the users ~/Library folder. You should always back up your Mac before removing any item found within a system directory. Here is what you’ll want to do and look for via the Finder:
- Quit out of any active web browser or any other app which uses Java
- From the Mac Finder, pull down the “Go” menu and choose “Go To Folder” and enter the following path:
- Locate and delete “JavaAppletPlugin.plugin” from this folder – note moving this item to the trash requires an admin login
- Now go back to the ‘Go’ menu and “Go To Folder” and enter the following path:
- Locate and delete “JavaControlPanel.prefPane” from this folder, again you will need an admin login
- Again return to the “Go” menu and “Go To Folder” to the following path:
- Remove the “Java” folder
- Empty the Trash on the Mac as usual
/Library/Internet Plug-ins/
/Library/PreferencePanes/
~/Library/Application Support/Java/
Java will be removed completely this way.
The Finder based approach is the easier and safer way to uninstall Java from a Mac, though Mac users can also remove Java and JRE via the command line as well.
Uninstalling Java and JRE from Mac OS Command Line
You can also uninstall Java from the command line by using the rm command, this is aimed for advanced users who understand the ramifications of using rm with superuser privileges. This is not for novice users, using the command line requires precise syntax and failure to use proper syntax may result in erroneous commands or unintended data loss.
One by one, execute each of the following commands individually:
sudo rm -rf "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin"
sudo rm -rf "/Library/PreferencePanes/JavaControlPanel.prefPane"
sudo rm -rf "~/Library/Application Support/Java"
This requires authenticating with sudo. Be certain you have the syntax 100% correct, if you are not sure if the syntax is correct do not execute the commands, and instead you’d likely want to use the Finder based approach of uninstalling java instead.
Note that whether you uninstall Java and JRE by command line or by the Mac Finder GUI, the result is the same, you are specifically removing the Java plugins, control panels, and application support for Java from the Mac.
You can always reinstall Java onto the Mac again at a later point if you decide to, or determine it’s necessary. Most Mac users do not need Java on their computers and thus won’t need to install it.
Have a Mac mini mid 2010 that I’am having trouble uninstalling JRE 8. I have tried both methods (rm commands in Terminal & also using Finder). my OSX 10.13 High Sierra
Thanks OSX Daily, do I have to also remove the ‘Oracle’ folder located in Application Support for Mojave?
Sometimes if there is java 11 on your pc… then to uninstall it here are the steps:
Navigate to /Library/Java/JavaVirtualMachines
and install your jdk 11 using above command
sudo rm -rf jdk_version_name_here
We resolved issues with Git Credential Manager by properly uninstalling and reinstalling Java. Here’s what worked for OS X High Sierra
sudo rm -rf “/Library/Internet Plug-Ins/JavaAppletPlugin.plugin”
sudo rm -rf “/Library/PreferencePanes/JavaControlPanel.prefPane”
sudo rm -rf “~/Library/Application Support/Oracle”
sudo rm -rf “~/Library/Java”
When upgrading to later OS X, I have an(a) app on my computer that requires Legacy Java. I wish I could find out which one it is because it is the only reason why I continue to reinstall Legacy Java. Does anyone know how to find what app requires it?
When upgrading to later OS X, I have an(a) app on my computer that requires Legacy Java. I wish I could find out which one it is because it is the only reason why I continue to reinstall Legacy Java. Does anyone know how to find what app requires it????
I’ve been having an ongoing issue with java where, upon starting the computer, it will insist that I update it (I think–been a long time since I read it). These demands will occur from 1-6x and I can do nothing until I keep hitting return. Tried re-installing/updating some months ago to no avail.
I hope this works because I detest this program and, since I am not someone who is able to easily deal with these things, want it GONE forevermore.
Well, it did not work. Poking around in LaunchAgents, I found “com.oracle.java.java-Updater.plist”. Seems as though I should trash this POS also. Found more java crapola in Preferences. Dumped all those. Next startup should be interesting.
I have just the opposite problem — getting Java to work reliably. I generally only want it for the Newsday and syndicated NY Times crossword puzzles, but it comes and goes on various browsers — Firefox, Chrome, Opera, and Safari. Currently it is working sometimes on Safari, sometimes not. Is there some other Mac browser that lets Java work more consistently?
for you kids at home, CS photoshop users need java to run the program, or something similar, so just be careful out there.
-don cheery
On my Mac’s there is also a Java direction at:
$ /Library/Java/…
The Java plugin is always contained within “/Library/Internet\ Plug-ins/” or “~/Library/Internet Plug-ins/”
If you don’t know what you’re doing you should not install Java in the first place. You do not need it.
The topic is “How to Uninstall Java on a Mac” and not “How to Uninstall Java Plug-in on a Mac”.
BTW the how to belongs only to the JRE, but there is also a JDK….
“On my Mac’s there is also a Java direction at:
$ /Library/Java/…”
On your Mac’s what?
Never mind. I now realize that you are one of those people who uses apostrophes when pluralizing nouns instead of showing possession or substituting for letters in contractions – can’t, don’t, etc.
I use an app called Appdelete, which works very well at removing all of the bits & pieces that many apps install. Do you know if Appdelete would work as thoroughly as you describe for Java?
AppDelete should be able to do the job. But since Java is not an “application” you have to go to /Library/PreferencePanes/ and from there, you can drag JavaControlPanel.prefPane on AppDelete window.
If you don’t need java don’t install it. Just like you wouldn’t clutter up with other stuff you don’t need.
Plus java is sometimes a security risk so what is the point of keeping it if you don’t need it for a specific app? Even then you have to keep it updated to maintain it.
… that makes sense, I suppose. Except in the twenty plus years I’ve used my Macs, I have had Java installed for all its usual purposes and can’t recall one instance of being asked to do a manual upgrade. I assume it’s still there and working but if not, I guess I don’t need it.
Awesome!
I’m sick of getting Java upgrade notices. Copy/Paste on the command line couldn’t have been easier. Thanks for posting this.
Please specify what Java does and does not, and if my Mac needs it, how could I figure it out.
My Mac has Software OS X 10.9.5 (13F1911). Thanks.
Is java bad?
If you Google – java bad – you will receive more information to answer your question.
… after reading through this post, I am still confused. I still don’t know why it might be useful to remove or disable Java. Can anyone shed some light on this for me?
java, flash, silverlight. all have security flaws/vulnerabilities. the evil hackers use these to hack into computers. if you remove these, you reduce the attack surface. they cant hack something that is not installed on your mac. Javascript is also bad but you can’t remove Javascript because most websites need it to work.
java, flash, silverlight, and Javascript are also used to track you. I’ve removed java, flash, and silverlight from my mac and windows 7 PC.