JavaScript Obfuscator Tool

A free and efficient obfuscator for JavaScript (including partial support of ES2019). Make your code harder to copy and prevent people from stealing your work. This tool is a Web UI to the excellent (and open source) javascript-obfuscator@2.6.3 created by Timofey Kachalov.

What is this?

This tool transforms your original JavaScript source code into a new representation that's harder to understand, copy, re-use and modify without authorization. The obfuscated result will have the exact functionality of the original code.

So, it is like UglifyJS, Closure Compiler, etc?

Yes and no. While UglifyJS (and others minifiers) does make the output code harder to understand (compressed and ugly), it can be easily transformed into something readable using a JS Beautifier.

This tool prevents that by using various transformations and "traps", such as self-defending and debug protection.

How does the obfuscation work?

Through a series of transformations, such as variable / function / arguments renaming, string removal, and others, your source code is transformed into something unreadable, while working exactly as before.

Read more in the FAQ...

Sounds great!

Just paste your code or upload it below and click on "obfuscate".

Also, be sure to read about all the options to understand all the trade-offs between code protection and code size / speed.

FAQ

Why would I want to obfuscate my JavaScript code?

There are numerous reasons why it's a good idea to protect your code, such as:

  • Prevent anyone from simply copy/pasting your work. This is specially important on 100% client side projects, such as HTML5 games;
  • Removal of comments and whitespace that aren't needed. Making it faster to load and harder to understand;
  • Protection of work that hasn't been paid for yet. You can show your work to the client knowing that they won't have the source code until the invoice has been paid.

Is this obfuscator absolutely foolproof?

No, while it's impossible to recover the exact original source code, someone with the time, knowledge and patience can reverse-engineer it.

Since the JavaScript runs on the browser, the browser's JavaScript engine must be able to read and interpret it, so there's no way to prevent that. And any tool that promises that is not being honest.

Why is my obfuscated code larger than my original source?

Because the obfuscator introduces new pieces of code that are meant to protect and defend against debugging and reverse-engineering. Also strings are converted to \xAB hexadecimal code to make things a little bit harder to understand. You don't have to worry too much about code size because there is a lot of repetition, so the obfuscated code will be compressed extremely well by your webserver (if you have GZIP compression enabled on your server, which most do nowadays).

Can I run a minifier such as UglifyJS or Google Closure Compiler on the obfuscated output?

No, it's not recommended and in some cases it'll break the code (such as if you enable self-defending). You can run your code through a minifier before to make sure that it removes dead code and do other optimizations, though.

Do you store my source code?

No. The source is processed by our application server, then to the obfuscator and back to the browser, so it only stays on our server memory for a brief period of time (usually milliseconds).

Can I recover the original source code from the obfuscated one?

No, it's impossible to revert the obfuscated code back to your original code, so keep the original safe.

Does this tool works with Node.js source code?

Yes.

I want to run the obfuscator on my own server/machine. Is it possible?

Sure. This tool uses a free and open source (BSD-2-Clause licensed) obfuscator written in TypeScript. You can go to its GitHub page and read more there.

There are also a number of plugins, such as: webpack-obfuscator, gulp-javascript-obfuscator and grunt-contrib-obfuscator.

Also, this web app is open-source as well. Check out our GitHub.

What are other similar tools?

If you're interested in just uglyfing and compressing your code, I suggest JSCompress.com.

Support project:

Also:
(Bitcoin) 14yhtZxLNp6ekZAgmEmPJqEKUP2VtUxQK6
(Ether) 0x5Df9eBcFB2D0f3315d03Ac112104b9023C409dc1
Big thanks to all supporters!