2023: splashout suggests in the comments the Vineflower/vineflower decompiler (releases), renaming from Quiltflower to Vineflower.

java -jar vineflower.jar -dgs=1 c:\Temp\binary\library.jar c:\Temp\souce

2022 update: QuiltMC/quiltflower is the latest most advanced Java decompiler:

Quiltflower is a modern, general purpose decompiler focused on improving code quality, speed, and usability.
Quiltflower is a fork of Fernflower and Forgeflower.

Changes include:

  • New language features (Try with resources, switch expressions, pattern matching, and more)
  • Better control flow generation (loops, try-catch, and switch, etc.)
  • More configurability
  • Better error messages
  • Javadoc application
  • Multithreading
  • Optimization
  • Many other miscellaneous features and fixes

Originally intended just for use with the QuiltMC toolchain with Minecraft, Quiltflower quickly expanded to be a general purpose java decompiler aiming to create code that is as accurate and clean as possible.

If the name sounds familiar it's because Quiltflower is a fork of Fernflower, the (in)famous decompiler that was developed by Stiver, maintained by Jetbrains, and became the default decompiler in Intellij IDEA.
Fernflower also quickly found its way into many other tools.

Over the past year, Quiltflower has added support for features such as modern string concatenation, a code formatter, sealed classes, pattern matching, switch expressions, try-with-resources, and more. Quiltflower also focuses on the code quality of the decompiled output, and takes readability very seriously.

See output examples.

Runs nice with jbang

https://github.com/QuiltMC/quiltflower/releases/download/1.8.1/quiltflower-1.8.1.jar

Or:

java -jar quiltflower.jar -dgs=1 c:\Temp\binary\library.jar c:\Temp\binary\Boot.class c:\Temp\source\

2009: JavaDecompiler can do a good job with a jar: since 0.2.5, All files, in JAR files, are displayed.

See also the question "How do I “decompile” Java class files?".

The JD-Eclipse doesn't seem to have changed since late 2009 though (see Changes).
So its integration with latest Eclipse (3.8, 4.2+) might be problematic.

JD-Core is actively maintained.

Both are the result of the fantastic work of (SO user) Emmanuel Dupuy.


2018: A more modern option, mentioned in the comments by David Kennedy Araujo:

JetBrains/intellij-community/plugins/java-decompiler/engine

Fernflower is the first actually working analytical decompiler for Java and probably for a high-level programming language in general.

java -jar fernflower.jar [-<option>=<value>]* [<source>]+ <destination>

java -jar fernflower.jar -hes=0 -hdc=0 c:\Temp\binary\ -e=c:\Java\rt.jar c:\Temp\source\

See also How to decompile to java files intellij idea for a command working with recent IntelliJ IDEA.


2022 update: Florian Wendelborn suggests in the comments

this one works well: jdec.app from Leonardo Santos.

Answer from VonC on Stack Overflow
🌐
Java Decompilers
javadecompilers.com
Java decompiler online
Java decompilers online: *JAD, *JDCore, *Procyon, *Fernflower, *CFR. ✓ A user interface to extract source code from .class and .jar ‘binary’ files.
Discussions

java - How to decompile a whole Jar file? - Stack Overflow
Remember two more things: 1) The mere mention of a decompiler will cause the "holier than thou's" to come out and make value judgements about your motives despite having no idea what your planned use is, so be careful who you talk to. 2) The fancy JavaDecompiler will give you an excellent rendition ... More on stackoverflow.com
🌐 stackoverflow.com
Should I be concerned about Java decompilers?
Please ensure that: Your code is properly formatted as code block - see the sidebar (About on mobile) for instructions You include any and all error messages in full You ask clear questions You demonstrate effort in solving your question/problem - plain posting your assignments is forbidden (and such posts will be removed) as is asking for or giving solutions. Trying to solve problems on your own is a very important skill. Also, see Learn to help yourself in the sidebar If any of the above points is not met, your post can and will be removed without further warning. Code is to be formatted as code block (old reddit: empty line before the code, each code line indented by 4 spaces, new reddit: https://imgur.com/a/fgoFFis ) or linked via an external code hoster, like pastebin.com, github gist, github, bitbucket, gitlab, etc. Please, do not use triple backticks (```) as they will only render properly on new reddit, not on old reddit. Code blocks look like this: public class HelloWorld { public static void main(String[] args) { System.out.println("Hello World!"); } } You do not need to repost unless your post has been removed by a moderator. Just use the edit function of reddit to make sure your post complies with the above. If your post has remained in violation of these rules for a prolonged period of time (at least an hour), a moderator may remove it at their discretion. In this case, they will comment with an explanation on why it has been removed, and you will be required to resubmit the entire post following the proper procedures. To potential helpers Please, do not help if any of the above points are not met, rather report the post. We are trying to improve the quality of posts here. In helping people who can't be bothered to comply with the above points, you are doing the community a disservice. I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns. More on reddit.com
🌐 r/javahelp
10
5
December 20, 2021
Looking for a Java decompiler
I've had a good experience with this one: http://jd.benow.ca/ EDIT: You decompile the .class file, which is a compiled .java file. A .jar file may contain .java files as well. More on reddit.com
🌐 r/java
49
28
June 13, 2017
New open source Java decompiler
Why didn't you just contribute these changes to Fernflower rather than forking? More on reddit.com
🌐 r/java
40
219
April 29, 2022
🌐
Jdec
jdec.app
JDec - Java Decompiler Online
JDec is a online Java decompiler that provides a fast way to decompile JAR files. Instant access to the files, no need to wait. Also supports downloading decompiled java code.
🌐
Shenmeapp
shenmeapp.com › decompiler
Java Decompiler Online - ShenmeApp
Java Decompiler Online streamlines the process—simply drag and drop your Java class files for instant decompilation.
Find elsewhere
🌐
Java Decompiler
java-decompiler.github.io
Java Decompiler
The “Java Decompiler project” aims to develop tools in order to decompile and analyze Java 5 “byte code” and the later versions.
🌐
Javainuse
javainuse.com › decomp
Java Decompiler Online
A CLASS file is a compiled .JAVA file created by the Java compiler. It contains bytecode, which is binary program code that is executable when run by a Java Virtual Machine (JVM). CLASS files are commonly bundled into .JAR files, which are included in the $CLASSPATH environment variable for ...
Top answer
1 of 8
401

2023: splashout suggests in the comments the Vineflower/vineflower decompiler (releases), renaming from Quiltflower to Vineflower.

java -jar vineflower.jar -dgs=1 c:\Temp\binary\library.jar c:\Temp\souce

2022 update: QuiltMC/quiltflower is the latest most advanced Java decompiler:

Quiltflower is a modern, general purpose decompiler focused on improving code quality, speed, and usability.
Quiltflower is a fork of Fernflower and Forgeflower.

Changes include:

  • New language features (Try with resources, switch expressions, pattern matching, and more)
  • Better control flow generation (loops, try-catch, and switch, etc.)
  • More configurability
  • Better error messages
  • Javadoc application
  • Multithreading
  • Optimization
  • Many other miscellaneous features and fixes

Originally intended just for use with the QuiltMC toolchain with Minecraft, Quiltflower quickly expanded to be a general purpose java decompiler aiming to create code that is as accurate and clean as possible.

If the name sounds familiar it's because Quiltflower is a fork of Fernflower, the (in)famous decompiler that was developed by Stiver, maintained by Jetbrains, and became the default decompiler in Intellij IDEA.
Fernflower also quickly found its way into many other tools.

Over the past year, Quiltflower has added support for features such as modern string concatenation, a code formatter, sealed classes, pattern matching, switch expressions, try-with-resources, and more. Quiltflower also focuses on the code quality of the decompiled output, and takes readability very seriously.

See output examples.

Runs nice with jbang

https://github.com/QuiltMC/quiltflower/releases/download/1.8.1/quiltflower-1.8.1.jar

Or:

java -jar quiltflower.jar -dgs=1 c:\Temp\binary\library.jar c:\Temp\binary\Boot.class c:\Temp\source\

2009: JavaDecompiler can do a good job with a jar: since 0.2.5, All files, in JAR files, are displayed.

See also the question "How do I “decompile” Java class files?".

The JD-Eclipse doesn't seem to have changed since late 2009 though (see Changes).
So its integration with latest Eclipse (3.8, 4.2+) might be problematic.

JD-Core is actively maintained.

Both are the result of the fantastic work of (SO user) Emmanuel Dupuy.


2018: A more modern option, mentioned in the comments by David Kennedy Araujo:

JetBrains/intellij-community/plugins/java-decompiler/engine

Fernflower is the first actually working analytical decompiler for Java and probably for a high-level programming language in general.

java -jar fernflower.jar [-<option>=<value>]* [<source>]+ <destination>

java -jar fernflower.jar -hes=0 -hdc=0 c:\Temp\binary\ -e=c:\Java\rt.jar c:\Temp\source\

See also How to decompile to java files intellij idea for a command working with recent IntelliJ IDEA.


2022 update: Florian Wendelborn suggests in the comments

this one works well: jdec.app from Leonardo Santos.

2 of 8
43

First of all, it's worth remembering that all Java archive files (.jar/.war/etc...) are all basically just fancy.zip files, with a few added manifests and metadata.

Second, to tackle this problem I personally use several tools which handle this problem on all levels:

  • Jad + Jadclipse while working in IDE for decompiling .class files
  • WinRAR, my favorite compression tool natively supports Java archives (again, see first paragraph).
  • Beyond Compare, my favorite diff tool, when configured correctly can do on-the-fly comparisons between any archive file, including jars. Well worth a try.

The advantage of all the aforementioned, is that I do not need to hold any other external tool which clutters my work environment. Everything I will ever need from one of those files can be handled inside my IDE or diffed with other files natively.

🌐
Reddit
reddit.com › r/javahelp › should i be concerned about java decompilers?
r/javahelp on Reddit: Should I be concerned about Java decompilers?
December 20, 2021 -

I don't know exactly how Java compiles it's programs but what I do know is that there are decompilers available online. So all assets and code I put into my software can be easily read if these were used. I would know I tested it. This is a concern? Is there things I can do to protect against this while maintaining readability?

Top answer
1 of 5
10
Java compiles code into byte code, which can then be read back using a decompiler. Although decompilers are often not 100% accurate, they're accurate enough to make it a security concern for many. If you want to protect yourself from your program's code being stolen, you can obfuscate your code. This is a process done during compilation by a separate program that makes your code not humanly readable, while still doing the same exact thing as before. This way, if someone decompiles your program, they won't have the original source code. Although de-obfuscation exists, it is much more difficult (and nearly impossible if your obfuscation is configured well). Obfuscating your product is highly recommended for securing your original source.
2 of 5
8
Somebody famous (I forgot who, sorry) told that actually there is exactly the opposite problem in the world: people cannot make somebody want to decompile their code. They spend enormous amount of time and money, but nobody cares. People pay money to advertise their github account, but nobody looks there. Even if it is a cure for cancer, people spends years to make others at least listen to them. I believe, a pragmatic approach is best here: what is the cost of somebody decompile the code? Why you want it to be hidden? Sometimes, hiding the code is not a very good idea. For example, it's almost a rule that a "brilliant" encryption algorithm that is hidden from society is going to be broken sooner than the exposed one.
🌐
Reddit
reddit.com › r/java › looking for a java decompiler
r/java on Reddit: Looking for a Java decompiler
June 13, 2017 -

I have a couple of .jar games on my disk. I want to decompile the bytecode back to the readable .java format.

What are my options? Google wasn't very helpful, throwing old sites at me with broken download links.

I just want to learn - I played the game lots of times so I know what it does, now I want to know how it does it.

EDIT: Thanks to everyone who replied, the post stays so that others can use. I decided to use jd-gui, but it's good to know many Java IDEs have plugins to do this too (I use Netbeans and I couldn't find a decompiler plugin for it)

🌐
Reddit
reddit.com › r/java › new open source java decompiler
r/java on Reddit: New open source Java decompiler
April 29, 2022 -

Hello! Today I'm happy to announce the release of a project that me and my friends have been working on over the course of the last year, Quiltflower! Originally intended just for use with the QuiltMC toolchain with Minecraft, Quiltflower quickly expanded to be a general purpose java decompiler aiming to create code that is as accurate and clean as possible. If the name sounds familiar it's because Quiltflower is a fork of Fernflower, the (in)famous decompiler that was developed by Stiver, maintained by Jetbrains, and became the default decompiler in Intellij IDEA. Fernflower also quickly found its way into many other tools. After many frustrations with it myself with its decompiled code structuring and quality I decided to do something about it, and here we are! Over the past year, Quiltflower has added support for features such as modern string concatenation, a code formatter, sealed classes, pattern matching, switch expressions, try-with-resources, and more. Quiltflower also focuses on the code quality of the decompiled output, and takes readability very seriously. We'd greatly appreciate it if you'd give it a try, with our Intellij Plugin, as a standalone jar, or on our maven. While it has come a long way it's still a work in progress, and feedback can be reported on our issue tracker.

Here's a comparison of Fernflower and Quiltflower's output.

I'd also like to thank the MinecraftForge Team for creating ForgeFlower, the fork that QuiltFlower was based on, and Lee Benfield for creating CFR and it's truly incredible test suite.

Top answer
1 of 16
588

Update February 2016:

www.javadecompilers.com lists JAD as being:

the most popular Java decompiler, but primarily of this age only. Written in C++, so very fast.
Outdated, unsupported and does not decompile correctly Java 5 and later

So your mileage may vary with recent jdk (7, 8).

The same site list other tools.

And javadecompiler, as noted by Salvador Valencia in the comments (Sept 2017), offers a SaaS where you upload the .class file to the cloud and it returns you the decompiled code.


Original answer: Oct. 2008

  • The final release of JSR 176, defining the major features of J2SE 5.0 (Java SE 5), has been published on September 30, 2004.
  • The lastest Java version supported by JAD, the famous Java decompiler written by Mr. Pavel Kouznetsov, is JDK 1.3.
  • Most of the Java decompilers downloadable today from the Internet, such as “DJ Java Decompiler” or “Cavaj Java Decompiler”, are powered by JAD: they can not display Java 5 sources.

Java Decompiler (Yet another Fast Java decompiler) has:

  • Explicit support for decompiling and analyzing Java 5+ “.class” files.
  • A nice GUI:

It works with compilers from JDK 1.1.8 up to JDK 1.7.0, and others (Jikes, JRockit, etc.).

It features an online live demo version that is actually fully functional! You can just drop a jar file on the page and see the decompiled source code without installing anything.

2 of 16
101

There are a few decompilers out there... A quick search yields:

  1. Procyon: open-source (Apache 2) and actively developed
  2. Krakatau: open-source (GPLv3) and actively developed
  3. CFR: open-source (MIT) and actively developed
  4. JAD
  5. DJ Java Decompiler
  6. Mocha

And many more.

These produce Java code. Java comes with something that lets you see JVM byte code (javap).

🌐
GitHub
github.com › java-decompiler
Java Decompiler · GitHub
JD-Core is a JAVA decompiler written in JAVA.
🌐
Quora
quora.com › Which-is-the-best-Java-decompiler
Which is the best Java decompiler? - Quora
Answer (1 of 4): I generally have used JD | Java Decompiler, in my career.Basically this has 3 main features. * JD Core-The base library which recovers the lost source code,and supports all new features of Java 5. * JD-GUI- Standalong GUI which displays the source code of the class files. * ...
🌐
JDoodle
jdoodle.com › online-java-compiler
Online Compiler and Editor/IDE for Java, C, C++, PHP, Python, Ruby, Perl - Code and Run Online
JDoodle is an Online Compiler, Editor, IDE for Java, C, C++, PHP, Perl, Python, Ruby and many more. You can run your programs on the fly online, and you can save and share them with others. Quick and Easy way to compile and run programs online.
🌐
Appscms
appscms.com › jar-decompiler
Safe Online JAR Decompiler
Java program developers can easily decompile JAR files with our online JAR Decompiler tool to extract source codes and other contents with ease.
Rating: 3 ​ - ​ 4 votes
🌐
DigitalOcean
digitalocean.com › community › tutorials › java-compiler
Java Decompiler Explained: How It Works, Tools, and Use Cases | DigitalOcean
June 19, 2025 - Tip: If you use IntelliJ IDEA or Eclipse, plugins like Fernflower and Enhanced Class Decompiler make the process seamless. Need something quick and accessible? Online Java decompilers let you view the contents of .class files without downloading any software.
🌐
Gracker
gracker.ai › cybersecurity-tools › java-decompiler-online
Java Decompiler Online - Security Testing AI Tool | AI Directory
This site offers a user interface that allows you to extract source code from .class and .jar 'binary' files. Until recently, using a Java decompiler was necessary, but all available options were either unstable, outdated, incomplete, or, at best, a combination of these issues.
🌐
Hypixel Forums
hypixel.net › home › forums › hypixel community › off topic
Is there a good java decompiler that's trustworthy with a good reputation? | Hypixel Forums
March 23, 2021 - a lot of mods state in their t0s that you do not have the right to decompile them, so while it is possible, it's legally questionable, but it's not like the police will come knocking on your door for it · Click to expand... Perhaps it lies in a legal grey zone like how some skyblock mods are. ... Click to expand... Yep ... eclipse is more for hardcore but it has a serious reputation, usually it is used to test java applications.
🌐
Benf
benf.org › other › cfr
CFR - yet another java decompiler.
CFR is a JVM bytecode decompiler - it will decompile modern Java features (including Java 13) but is written entirely in Java 6, so will work anywhere! - It'll even make a decent go of turning class files from other JVM languages (eg Kotlin, Scala, Groovy) back into Java!