yGuard is a free Java bytecode obfuscator and shrinker that improves your software deployment by prohibiting unwanted access to your source code and drastically shrinking the processed Jar files at the same time.
- yGuard is now fully open source! Obfuscate your code in just minutes in Ant, Maven and Gradle.
- You can find the tool with the source code on GitHub.
- yGuard is absolutely free! Contrary to expensive commercial products of our competitors providing the same amount of features as yGuard or less, yGuard is free.
- yGuard is an Ant task! Existing tools use proprietary mechanisms to invoke or configure the task of obfuscation. As an Ant task, yGuard can be seamlessly integrated into your deployment process using XML syntax.
- yGuard provides highly configurable name obfuscation that will protect your intellectual property from reverse engineering.
- yGuard provides elaborate code shrinking functionality through dependency analysis.
- yGuard 2.0 offers a new powerful and easy to use XML syntax that allows the effortless definition of code entities e.g. based on pattern sets or inheritance.
- yGuard will correctly obfuscate and shrink programs that depend on external libraries.
- yGuard can automatically rename and adjust textual resource files according to the obfuscation scheme.
- yGuard can scramble and unscramble or shrink line number table information. This means that debugging an obfuscated program is still achievable without weakening the obfuscation.
- yGuard can create patches! During each obfuscation run, yGuard produces XML output that can be used to create subsequent patches of already deployed obfuscated applications.
- yGuard supports JDK 1.5 features and correctly obfuscates classes compiled with its new features.
- Name Obfuscation: protects your
.classfiles from reverse engineering by replacing package, class, method, and field names with inexpressive characters. If afterwards the obfuscated
.classfiles are decompiled, it will be extremely difficult to derive the original purpose of the obfuscated code entities.
As an additional side-effect, name obfuscation will significantly reduce the size of your application, depending on the chosen mapping scheme.
- Code Shrinking: drastically reduces the size of the input Jar files if your application does not use all of the contained bytecode.
The shrinking engine analyzes the bytecode of all input Jar files in order to determine which code entities can not be reached from a set of given code entry points. These obsolete code fragments (either entire classes or single methods and fields) will then be removed by yGuard. If you use any third party libraries, you will probably benefit a lot from the yGuard shrinking engine, since applications usually do not use all of the functionality provided by an external library and a large fraction of the contained bytecode and resources can be safely removed.
Java 11 Compatibility
Beginning with version 2.7, yGuard supports obfuscation of Java class files that contain
nestmembers attributes which were introduced with the Java 11
.class file format.
yGuard does not support obfuscating
dynamic instructions which were introduced with the Java 11
.class file format.
Java 9 / Java 10 Compatibility
Beginning with version 2.7, yGuard supports obfuscation of Java class files that contain module information which was introduced with the Java 9
.class file format. yGuard does not change module names, though.
yGuard does not support obfuscating multi-release Java archives which were introduced with Java 9.
Java 7 / Java 8 Compatibility
Beginning with version 2.5, yGuard supports obfuscation of Java class files that contain the
invokedynamic instruction, which was introduced with the Java 7
.class file format.
JDK 7 does not contain any means of issuing this instruction, with JDK 8 it is being issued when using lambda expressions or default methods.
While yGuard does fully support obfuscating
invokedynamic instructions and therefore default methods and lambda expressions, shrinking of Java class files that contain the
invokedynamic instruction is not supported yet.
The data you enter will only be used to contact you.
Your message has been sent to email@example.com
Your request could not be sent to firstname.lastname@example.org. Please reload the page and try again.
If the problem persists, please report the error to email@example.com