Obfuscation presets available in JavaScript Obfuscator GUI

Quick navigation:


Available presets for code mangling:

Original code (before protection):
var  error_level  =  4;  /*  error  level  to  show  alerts  for*/
function  log_error(whereStr,msg)
{
        log_common(3,"error:"  +  whereStr,msg);  //call  common  function
}
function  log_common(lvl,whereStr,msg)
{
        var  buf  =  '<div  class=logitem>'  +  new  Date()  +    whereStr  + 
                  msg  +  '</div>'
        if  (lvl  >=  error_level)
                alert(buf);
        errlog.write(buf);
}
This is a trivial JavaScript code with 1 global var, 2 functions that refer to it and have local variables or parameters of the same name.

 

Mode testing - recommended for stage 1:
var  ReplacementFor_error_level  =  4;   
function  ReplacementFor_log_error(ReplacementFor_whereStr,ReplacementFor_msg)
{
        ReplacementFor_log_common(3,"error:"  +  ReplacementFor_whereStr,ReplacementFor_msg); 
};
function  ReplacementFor_log_common(ReplacementFor_lvl,ReplacementFor_whereStr,ReplacementFor_msg)
{
        var  ReplacementFor_buf  =  '<div  class=logitem>'  +  new  Date()  +    ReplacementFor_whereStr  + 
                  ReplacementFor_msg  +  '</div>';
        if  (ReplacementFor_lvl  >=  ReplacementFor_error_level)
                alert(ReplacementFor_buf);
        ReplacementFor_errlog.write(ReplacementFor_buf);
};

Whitespaces are not jammed, so line numbers should be same as in original code. Symbols that will be renamed get ReplacementFor_ prefix. Best mode for preparation your code for protection and testing protected output.
    Details

This preset is ideal for preparing your code for protection and testing protected code:
  • Line numbers in protected code should match ones in original code;
  • Whitespaces are not jammed in code;
  • Comments are replaced with same number of newlines;
  • encoding, integer and string mangling are turned off;
  • symbols that will be replaced with unreadable names in production mode will get prefix "ReplacementFor_" when using this mode.

WHEN TO USE: This preset is for stage when you just prepare your code for protection, mostly when you collect names of symbols that can't be changed. Using this preset allows to receive informative error messages from compilers/interpreters your code is written for.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode testing - recommended for stage 2 (same as stage 1 + whitespace jamming enabled):
var  ReplacementFor_error_level=4;
function  ReplacementFor_log_error(ReplacementFor_whereStr,ReplacementFor_msg){
ReplacementFor_log_common(3,"error:"+ReplacementFor_whereStr,ReplacementFor_msg);};
function  ReplacementFor_log_common(ReplacementFor_lvl,ReplacementFor_whereStr,ReplacementFor_msg){
var  ReplacementFor_buf='<div  class=logitem>'+new  Date()+ReplacementFor_whereStr+
ReplacementFor_msg+'</div>';
if(ReplacementFor_lvl>=ReplacementFor_error_level)alert(ReplacementFor_buf);
ReplacementFor_errlog.write(ReplacementFor_buf);
};

Whitespaces are jammed. Symbols that will be renamed get ReplacementFor_ prefix. Prepare your code for protection using this mode too after testing it protected with previous mode to check whether removal of line breaks will affect your code (it should not!! but it would be easier to detect the problem caused by newline removal using this preset rather than production presets).
    Details

These presets are optimized for preparing your code for protection:
  • Whitespaces are jammed in the code;
  • Comments are removed;
  • encoding, integer and string mangling are turned off so you get informative error messages from compilers/interpreters;
  • symbols that will be replaced with unreadable names in production mode will get prefix "ReplacementFor_" when using this mode.
WHEN TO USE: This preset is for stage when you've finished preparing your code for protection and wish to try it protected with jamming enabled. Jamming spaces and removal of comments is unlikely to create issues, but it's better to test how jammed code works by trying this preset first. If your code works with this preset, it's safe to use any of production presets here.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode testing - recommended for stage 3 (same as stage 2 + minify locals):
var  ReplacementFor_error_level=4;function  ReplacementFor_log_error(A,B){ReplacementFor_log_common(3,"error:"+A,B);}function  ReplacementFor_log_common(B,C,D){var  A="<div  class=logitem>"+new  Date()+C+D+"</div>";if(B>=ReplacementFor_error_level){alert(A);}ReplacementFor_errlog.write(A);}
Whitespace is jammed, comments are removed. Local variables get renamed to shortest name possible, other symbol names get prefix ReplacementFor_ prefix. Use this for testing your code.
    Details

These presets are optimized for preparing your code for protection with local variables renamed before obfuscation:
  • Whitespaces are jammed in the code;
  • Comments are removed;
  • encoding, integer and string mangling are turned off so you get informative error messages from compilers/interpreters;
  • symbols that will be replaced with unreadable names in production mode will get prefix "ReplacementFor_" when using this mode.
  • local variables get renamed to shortest name possible with prefix for "ReplacementFor_LOCALVAR_"
WHEN TO USE: This preset is for stage when you've finished preparing your code for protection and wish to try it protected with jamming enabled and with local variables renamed (renaming local vars is a must if you are going to compress (minify) your code afterwards). Jamming spaces and removal of comments is unlikely to create issues, but it's better to test how jammed code works by trying this preset first. If your code works with this preset, it's safe to use any of production presets here.

It does not make sense to spend time trying this preset if you are NOT planning to compress (aka minify your code); try it only if you protect your code with local variables renamed.

It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode lite protection - protect everything but leave symbol names as is:
var  error_level=(0x5fc+5097-0x19e1);function  log_error(whereStr,msg){log_common((0xd70+5106-0x215f),"\x65\x72\x72\x6f\x72\x3a"+whereStr,msg);};function  log_common(lvl,whereStr,msg){var  buf="\x3c\x64\x69\x76\x20\x63\x6c\x61\x73\x73\x3d\x6c\x6f\x67\x69\x74\x65\x6d\x3e"+new  Date()+whereStr+msg+"\x3c\x2f\x64\x69\x76\x3e";if(lvl>=error_level)alert(buf);errlog.write(buf);};
No symbol names are changed. Comments are removed, whitespace is jammed. String and integer constants are obfuscated.This can be used when you don't have time to test your code afer obfuscation at all; the code after obfuscation should work exactly as before obfuscation.
    Details

When this preset is selected, all obfuscation stages except renaming of symbols are performed:
  • comments are removed
  • whitespaces are jammed
  • strings and integers are mangled
WHEN TO USE: When this preset is selected, symbol names are not changed. This means there is no need to compose list of exceptions (names of symbols that can't be changed) and test whether code works afterwards. Since gathering exceptions is most time-consuming part, use of this mode allows to get some protection very quickly. Output should work exactly the same as original code, so extensive testing of protected code is not required.
PLEASE NOTE When this mode is selected, it's still possible to use asserters for licensing conditions (expiration, binding to domain name and user-implemented asserters).
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode lite protection - jam and minify local vars only:
var  error_level=4;function  log_error(A,B){log_common(3,"error:"+A,B);}function  log_common(B,C,D){var  A="<div  class=logitem>"+new  Date()+C+D+"</div>";if(B>=error_level){alert(A);}errlog.write(A);}
Whitespace is jammed, comments are removed, integer and string constants are mangled. Local variables change their name to shortest name possible; all other symbol names are unchanged. Use this mode if you do not have time to test your code after obfuscation, but wish it to be more cryptic than just after minifying.
    Details

Applying this preset does what YUICompressor does (but it handles not only raw .js files, but scripts in html files too, and it does everything WAY faster than YUICompressor!)
  • comments are removed
  • whitespaces are jammed
  • strings and integers are NOT mangled
  • names of local variables replaced with shortest name possible for given scope
  • names of global vars and functions are left unmodified
WHEN TO USE: Use this when you wish to minimize download size of your code. When this preset is selected, symbol names for global variables are not changed. This means there is no need to compose list of exceptions (names of symbols that can't be changed) and test whether code works afterwards. Output should work exactly the same as original code, so extensive testing of protected code is not required.
PLEASE NOTE When this mode is selected, it's still possible to use asserters for licensing conditions (expiration, binding to domain name and user-implemented asserters).
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode lite protection - just remove comments, do not change anything else:
var  error_level  =  4; 
function  log_error(whereStr,msg)
{
        log_common(3,"error:"  +  whereStr,msg);  };
function  log_common(lvl,whereStr,msg)
{
        var  buf  =  '<div  class=logitem>'  +  new  Date()  +    whereStr  + 
                  msg  +  '</div>';
        if  (lvl  >=  error_level)
                alert(buf);
        errlog.write(buf);
};

Only comments are removed, nothing else is changed.
    Details

When this preset is applied, only comments are removed. No obfuscation and no whitespace jamming is performed.
WHEN TO USE: This is useful if you wish to just remove comments (and possibly encode file afterwards) without spending any time and effort for preparing your project for obfuscation (i.e. collecting symbol names that can't be changed)
PLEASE NOTE It's impossible to use licensing conditions asserters when using this preset.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode lite protection - do not parse source at all and do not change it:
var  error_level  =  4;  /*  error  level  to  show  alerts  for*/
function  log_error(whereStr,msg)
{
        log_common(3,"error:"  +  whereStr,msg);  //call  common  function
}
function  log_common(lvl,whereStr,msg)
{
        var  buf  =  '<div  class=logitem>'  +  new  Date()  +    whereStr  + 
                  msg  +  '</div>'
        if  (lvl  >=  error_level)
                alert(buf);
        errlog.write(buf);
}

Code is same as original (i.e. it's not changed). This mode is useful if you plan to apply encoding to the code - as a result, your code won't be readable and you won't have to test it. We don't recommend you to use this mode anyway, even if you enable encoding for the code.
    Details

No parsing and no transformation are performed (i.e. no jamming, no comment removal, no symbol renaming, no string and number obfuscation).

Asserters (binding to domain name, expiration and user-implemented licensing conditions validation) offer only weak protection when this mode is selected.

WHEN TO USE:This mode is useful only if you wish to just encode your files. This will "hide" your code, but protection won't be irreversable. Apply this mode if you don't have time to prepare code for obfuscation.
It's greatly advicable to use 'jam and obfuscate everything, but do not change symbol names' preset instead of this preset - it also won't require any time for preparing for obfuscation, but at it will remove comments, jam spaces and will obfuscate strings and numbers.

It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - md5 engine for all symbols:
var  zfafb4b3d80=(0xa25+7336-0x26c9);function  z9fe5826ce8(zce55a28aab,zea4cd01646){za56048cb23((0x15d2+865-0x1930),"\x65\x72\x72\x6f\x72\x3a"+zce55a28aab,zea4cd01646);};function  za56048cb23(z0799d4fdb1,zce55a28aab,zea4cd01646){var  z1f7dba04b5="\x3c\x64\x69\x76\x20\x63\x6c\x61\x73\x73\x3d\x6c\x6f\x67\x69\x74\x65\x6d\x3e"+new  Date()+zce55a28aab+zea4cd01646+"\x3c\x2f\x64\x69\x76\x3e";if(z0799d4fdb1>=zfafb4b3d80)alert(z1f7dba04b5);z9df02a65fb.write(z1f7dba04b5);};
Production mode with md5 mangler for all symbols. Comments are removed, whitespace is jammed, strings and integers are mangled too.
    Details

This is a default preset for production.
  • All symbols are replaced with their md5 hash (with some seed) if using non-trial version (in trial version, all symbols will be just prefixed with a string "ReplacementFor_")
  • encoding is enabled (if encoding-related preset permits encoding)
  • integer and string mangling is on
  • comments are removed.
  • whitespaces are jammed everywhere.
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit or test your project.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - replace symbols with "lI":
var  lIlIl=(0x1532+3397-0x2273);function  IlIll(lllll,IlIII){llIll((0xdc5+631-0x1039),"\x65\x72\x72\x6f\x72\x3a"+lllll,IlIII);};function  llIll(IIlll,lllll,IlIII){var  lIlll="\x3c\x64\x69\x76\x20\x63\x6c\x61\x73\x73\x3d\x6c\x6f\x67\x69\x74\x65\x6d\x3e"+new  Date()+lllll+IlIII+"\x3c\x2f\x64\x69\x76\x3e";if(IIlll>=lIlIl)alert(lIlll);IIlIl.write(lIlll);};
Production mode with mangler that turns all symbols into names like IIlIllI. Comments are removed, whitespace is jammed, strings and integers are mangled too.
    Details

  • All symbols are replaced with combinations of 'I' and 'l' (e.g. "lIIIl") if using non-trial version (with trial version, all symbols will be just prefixed with a string "ReplacementFor_")
  • encoding is enabled (if encoding-related preset permits encoding)
  • integer and string mangling is on
  • comments are removed.
  • whitespaces are jammed everywhere.
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit or test your project.
It's not recommended to change ANY setting in this mode except settings in section "Obfuscation engines' options"!

Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE'.

Mode production - replace non-local vars with "lI" and minify locals:
var  IIIll=4;function  IIIII(A,B){IlIIl(3,"error:"+A,B);}function  IlIIl(B,C,D){var  A="<div  class=logitem>"+new  Date()+C+D+"</div>";if(B>=IIIll){alert(A);}IIIlI.write(A);}
Production mode with mangler that turns all symbols that are not local vars into names like IIlIllI; local variables and function arguments get shortest name possible in each scope (as you can see, function argument whereStr got renamed to different names in different functions). Comments are removed, whitespace is jammed, strings and integers are left as is. This mode is useful if you wish protected code be rather compact (it will be, since local variables will get shortest name possible) but also cryptic.
    Details

This turns all symbols except local variables into combinations of 'I' and 'l'; local variables are minified, so that output will have reasonable size.
  • All symbols are not local variable names are replaced with combinations of 'I' and 'l' (e.g. "lIIIl") if using non-trial version (with trial version, all symbols will be just prefixed with a string "ReplacementFor_")
  • encoding is enabled (if encoding-related preset permits encoding)
  • integer and string mangling is OFF
  • comments are removed.
  • whitespaces are jammed everywhere.
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit or test your project.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - replace all symbols with "lI" after minifying locals:
var  IIlll=(0xe59+1911-0x15cc);function  llIIl(IlIII,lIlll){lIlIl((0x115f+3434-0x1ec6),"\x65\x72\x72\x6f\x72\x3a"+IlIII,lIlll);}function  lIlIl(lIlll,llIll,IIlIl){var  IlIII="\x3c\x64\x69\x76\x20\x63\x6c\x61\x73\x73\x3d\x6c\x6f\x67\x69\x74\x65\x6d\x3e"+new  Date()+llIll+IIlIl+"\x3c\x2f\x64\x69\x76\x3e";if(lIlll>=IIlll){alert(IlIII);}IlIIl.write(IlIII);}
Production mode with mangler that turns all symbols into names like IIlIllI; local variables and function arguments get different names in each function for added protection (as you can see, function argument whereStr got renamed to different names in different functions). Comments are removed, whitespace is jammed, strings and integers are mangled.
    Details

This turns all symbols into combinations of 'I' and 'l'; local variables are minified before obfuscation.
  • All symbols are not local variable names are replaced with combinations of 'I' and 'l' (e.g. "lIIIl") if using non-trial version (with trial version, all symbols will be just prefixed with a string "ReplacementFor_")

    Local variables are minified before obfuscation. so if local variable 'foo' is declared in 2 functions, after protection with this preset it will be renamed to different name in different functions. This produces bigger code than when local variables are only minified (while the rest of vars is obfuscated) and is slightly more confusing.

  • encoding is enabled (if encoding-related preset permits encoding)
  • integer and string mangling is ON
  • comments are removed.
  • whitespaces are jammed everywhere.
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit or test your project.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - md5 engine for all but locals, minify local vars:
var  zfafb4b3d80=4;function  z9fe5826ce8(A,B){za56048cb23(3,"error:"+A,B);}function  za56048cb23(B,C,D){var  A="<div  class=logitem>"+new  Date()+C+D+"</div>";if(B>=zfafb4b3d80){alert(A);}z9df02a65fb.write(A);}
Production mode with mangler that renames all symbols that are not names of local variables using md5 mangler; local variables and function arguments get shortest name possible in each scope (as you can see, function argument whereStr got renamed to different names in different functions). Comments are removed, whitespace is jammed, strings and integers are left as is. This mode is useful if you wish protected code be rather compact (it will be, since local variables will get shortest name possible) but also cryptic.
    Details

Production mode; names of local variables are minified, all other symbols processed using md5 engine. This keeps your code rather compact, but difficult to study since names of global vars and functions and property names are md5-obfuscated.
  • All symbols but names of local vars are replaced with their md5 hash (with some seed) if using non-trial version (in trial version, all symbols will be just prefixed with a string "ReplacementFor_")
  • encoding is enabled (if encoding-related preset permits encoding)
  • integer and string mangling is OFF
  • comments are removed.
  • whitespaces are jammed everywhere.
PLEASE NOTE: In trial edition all symbols except local vars will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit or test your project.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - md5 engine for symbols after minifying locals:
var  zfafb4b3d80=(0x550+1066-0x976);function  z9fe5826ce8(z0bf8c0e6c8,z26241da7c7){za56048cb23((0x1cf+6841-0x1c85),"\x65\x72\x72\x6f\x72\x3a"+z0bf8c0e6c8,z26241da7c7);}function  za56048cb23(z26241da7c7,z3309f8f2aa,z2e4d4a9bbf){var  z0bf8c0e6c8="\x3c\x64\x69\x76\x20\x63\x6c\x61\x73\x73\x3d\x6c\x6f\x67\x69\x74\x65\x6d\x3e"+new  Date()+z3309f8f2aa+z2e4d4a9bbf+"\x3c\x2f\x64\x69\x76\x3e";if(z26241da7c7>=zfafb4b3d80){alert(z0bf8c0e6c8);}z9df02a65fb.write(z0bf8c0e6c8);}
Production mode with mangler that renames all symbols using md5 mangler; local variables and function arguments get different names in each function for added protection (as you can see, function argument whereStr got renamed to different names in different functions). Comments are removed, whitespace is jammed, strings and integers are mangled.
    Details

Production mode; all symbols protected with md5 obfuscation. Local variables are minified before obfuscation.
  • All symbols are replaced with their md5 hash (with some seed) if using non-trial version (in trial version, all symbols will be just prefixed with a string "ReplacementFor_").

    Local variables are minified before obfuscation. so if local variable 'foo' is declared in 2 functions, after protection with this preset it will be renamed to different name in different functions. This produces bigger code than when local variables are only minified (while the rest of vars is obfuscated) and is slightly more confusing.

  • encoding is enabled (if encoding-related preset permits encoding)
  • integer and string mangling is on
  • comments are removed.
  • whitespaces are jammed everywhere.
PLEASE NOTE: In trial edition all symbols except local vars will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit or test your project.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - minimize size of output:
var  e=4;function  h(X,T){l(3,"error:"+X,T);};function  l(c,X,T){var  a='<div  class=logitem>'+new  Date()+X+T+'</div>';if(c>=e)alert(a);o.write(a);};
All symbols get shortest name possible (though without considering their scope). Comments are removed, whitespace is jammed, integer and string constants are left as is.
    Details

When this mode is applied, the output will have minimal size:
  • all symbols are given shortest name possible if using non-trial version (with trial version, all symbols will be just prefixed with a string "ReplacementFor_")
  • encoding is disabled
  • integer and string mangling is NOT performed
  • comments are removed
  • whitespaces are jammed
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit or test your project again.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - replace symbols with permutations of characters:
var  PKQRd=(0x10a1+1595-0x16d8);function  XSzki(Xilv5,VJ7uY){jWyBi((0xffc+2924-0x1b65),"\x65\x72\x72\x6f\x72\x3a"+Xilv5,VJ7uY);};function  jWyBi(VHtKX,Xilv5,VJ7uY){var  lypS6="\x3c\x64\x69\x76\x20\x63\x6c\x61\x73\x73\x3d\x6c\x6f\x67\x69\x74\x65\x6d\x3e"+new  Date()+Xilv5+VJ7uY+"\x3c\x2f\x64\x69\x76\x3e";if(VHtKX>=PKQRd)alert(lypS6);COUQ7.write(lypS6);};
Production mode with "combs" mangler for all symbols (turning each symbol into combination of characters). Comments are removed, whitespace is jammed, strings and integers are mangled too.
    Details

When this mode is applied, the output all symbols will become random permuations of all characters possible for identifier (looking more random compared to default md5 engine). No disadvantages compared to preset that uses md5!
  • all symbols are given names consisting random set of characters, not only characters that can be used in hex digit if using non-trial version (in trial version, all symbols will be just prefixed with a string "ReplacementFor_")
  • encoding is disabled
  • integer and string mangling is NOT performed
  • comments are removed
  • whitespace is jammed
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit your project.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - replace non-locals with permutations of characters and minify locals:
var  WSWZs=4;function  IOoDm(A,B){mD6fx(3,"error:"+A,B);}function  mD6fx(B,C,D){var  A="<div  class=logitem>"+new  Date()+C+D+"</div>";if(B>=WSWZs){alert(A);}NXn94.write(A);}
Production mode with mangler that turns all symbols that are not local vars into random names; local variables and function arguments get shortest name possible in each scope (as you can see, function argument whereStr got renamed to different names in different functions). Comments are removed, whitespace is jammed, strings and integers are left as is. This mode is useful if you wish protected code be rather compact (it will be, since local variables will get shortest name possible) but also cryptic.
    Details

When this mode is applied, all symbols that are not names of local variables will become random permuations of all characters possible for identifier (looking more random compared to default md5 engine). No disadvantages compared to preset that uses md5! Names of local variables will be given as short names as possible.
  • all symbols that are not local variables are given random names from set of characters, not only characters that can be used in hex digit (as in case with md5) if using non-trial version (in trial version, all symbols will be just prefixed with a string "ReplacementFor_")

    Local variables are minified before obfuscation. so if local variable 'foo' is declared in 2 functions, after protection with this preset it will be renamed to different (as short as possible) name in different functions. This results in rather small output size.

  • encoding is disabled
  • integer and string mangling is NOT performed
  • comments are removed
  • whitespace is jammed
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit your project.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - replace all symbols with permutations of characters after minifying locals:
var  U5rwr=(0x839+468-0xa09);function  fsK9Y(Kp3oI,NQZG6){bagCU((0x2f8+5780-0x1989),"\x65\x72\x72\x6f\x72\x3a"+Kp3oI,NQZG6);}function  bagCU(NQZG6,m3Ra6,IIf3P){var  Kp3oI="\x3c\x64\x69\x76\x20\x63\x6c\x61\x73\x73\x3d\x6c\x6f\x67\x69\x74\x65\x6d\x3e"+new  Date()+m3Ra6+IIf3P+"\x3c\x2f\x64\x69\x76\x3e";if(NQZG6>=U5rwr){alert(Kp3oI);}EO_1q.write(Kp3oI);}
Production mode with mangler that renames all symbols by using random characters; local variables and function arguments get different names in each function for added protection (as you can see, function argument whereStr got renamed to different names in different functions). Comments are removed, whitespace is jammed, strings and integers are mangled.
    Details

When this mode is applied, all symbols will become random permuations of all characters possible for identifier (looking more random compared to default md5 engine). No disadvantages compared to preset that uses md5! Names of local vars will be minified before such replacement resulting in even more cryptic code.
  • all symbols that are not local variables are given random names from set of characters, not only characters that can be used in hex digit (as in case with md5) if using non-trial version (in trial version, all symbols will be just prefixed with a string "ReplacementFor_")

    Local variables are minified before obfuscation. so if local variable 'foo' is declared in 2 functions, after protection with this preset it will be renamed to different (as short as possible) name in different functions.

  • encoding is disabled
  • integer and string mangling is NOT performed
  • comments are removed
  • whitespace is jammed
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit your project.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode production - minimize size of output after minifying locals:
var  N=4;function  h(L,a){W(3,"error:"+L,a);}function  W(a,k,l){var  L="<div  class=logitem>"+new  Date()+k+l+"</div>";if(a>=N){alert(L);}p.write(L);}
All symbols get shortest name possible, with respect to their scope! This gives most compact output possible. Comments are removed, whitespace is jammed, integer and string constants are left as is.
    Details

When this mode is applied, the output will have minimal size:
  • all symbols are given shortest name possible if using non-trial version (with trial version, all symbols will be just prefixed with a string "ReplacementFor_")

    Local variables are minified before obfuscation. so if local variable 'foo' is declared in 2 functions, after protection with this preset it will be renamed to different (as short as possible) name in different functions. This results in much smaller output compared to preset when no minifying of local variables is performed.

  • encoding is disabled
  • integer and string mangling is NOT performed
  • comments are removed
  • whitespaces are jammed
PLEASE NOTE: In trial edition all symbols will be just prefixed with a string "ReplacementFor_" !! Once you purchase a product from the store, real symbol obfuscation will be performed without need to edit or test your project again.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...

Available presets for encoding of code:

Original code (before protection):
Raw code sample
var  blah  =12;  //intentionally  short  script  to  make
        //encoded  version  short
function  fn1(arg1)  {  blah  *=  arg1;  }

Code inside markup
<html>
<script>
<!--
var  blah  =12;
function  fn1(arg1)  {  blah  *=  arg1;  }
-->
</script>
no comment

 

Mode no encoding:
Raw code sample
var  z193a2e9280=(0x63b+1361-0xb80);function  zfed78b91fd(z833aebdda5){z193a2e9280
*=z833aebdda5;};

Code inside markup
<html>  <script><!--
var  z193a2e9280=(0x22f0+500-0x24d8);function 
zfed78b91fd(z833aebdda5){z193a2e9280*=z833aebdda5;};
--></script> 
No encoding at all.
    Details

This mode turns off encoding for files of all kinds.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode encode only raw code:
Raw code sample
var  xVdGua  =  unescape('{var  xmWqWZ  %3D  %27v%2561r%2520%257a%25319%2533a%2532e%25392%2538%2530%253d%2528%2530x%2535e%2566%252B2%25336%2537%252d0%2578f%25322%2529%253Bf%2575n%2563%2574%2569%256Fn%2520%257a%2566%2565d%25378%2562%2539%2531f%2564%2528%257a%25383%2533a%2565b%2564%2564%2561%2535%2529%257b%257a%2531%2539%2533a%2532%2565%25392%2538%2530%250a*%253dz%25383%2533%2561e%2562d%2564%2561%2535%253B%257D%253b%250A%27;;function  __zb8%28z94%29{return  unescape%28z94%29;};;  xmWqWZ  %3d  __zb8%28xmWqWZ%29;  eval%28xmWqWZ%29;  xmWqWZ  %3D  %27%27;  }');{var  z82="\x5c";function  __z9b(z07){while(z82.length<(0x5b0+4306-0x15ba)){z82+=z82+z82+z82+z82+z82;}var  z84='',z5d=(0x613+5902-0x1d21);while((0x6ae+4399-0x17dc)){var  zff=z07.indexOf("\x5e",z5d);if(zff==-(0x2203+1166-0x2690))return  z84+z07.substr(z5d);else{z84+=z07.substr(z5d,zff-z5d);var  zd1=(0x1e93+1313-0x23b2);var  z21=z07.charAt(zff+(0x907+1781-0xffb));while((0x1451+3608-0x2268)){var  zab=z07.charAt(zff+zd1++);if(!(zab>="\x30"&&zab<="\x39"))break;else  z21+=zab;}z21=parseInt(z21);z5d=zff+zd1-(0x194+2657-0xbf4);do{var  z14=z21>z82.length?z82.length:z21;z21-=z14;z84+=z82.substr((0x27b+7467-0x1fa6),z14);}while(z21>z82.length);}}return  z84;}};xVdGua  =  __z9b(xVdGua);eval(xVdGua);

Code inside markup
<html>  <script><!--
var  z193a2e9280=(0x1f0f+1972-0x26b7);function 
zfed78b91fd(z833aebdda5){z193a2e9280*=z833aebdda5;};
--></script> 
Encoding is enabled in files with raw code. Pieces of code inside files with html markup are not encoded.
    Details

This preset turns on encoding for raw JS code (in files with js extension and the like), JS code embedded into .html/.php/.asp/.aspx files and the like won't be encoded.

PLEASE NOTE: When "testing" or "production: minimize size" code mangling is selected using Settings ⇒ Select preset for code mangling.., encoding is effectively disabled.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode encode ALL code:
Raw code sample
var  xPgGAr  =  unescape('{var  xAcyCd  %3d  %27%2576%2561%2572%2520z%2531%2539%2533a%2532e%2539%2532%25380%253d%2528%2530x%2536%25638%252B6%2536%2535%252d%2530x%2539%25355%2529%253b%2566%2575n%2563%2574i%256Fn%2520%257a%2566%2565d%2537%2538%2562%25391%2566%2564%2528%257a8%25333%2561%2565b%2564%2564%25615%2529%257bz%2531%25393%25612%25659%25328%2530%250a%252A%253D%257a%25383%2533%2561e%2562d%2564%2561%2535%253B%257d%253B%250a%27;;function  __zb8%28z94%29{return  unescape%28z94%29;};;  xAcyCd  %3D  __zb8%28xAcyCd%29;  eval%28xAcyCd%29;  xAcyCd  %3D  %27%27;  }');{var  z82="\x5c";function  __z9b(z07){while(z82.length<(0x5b0+4306-0x15ba)){z82+=z82+z82+z82+z82+z82;}var  z84='',z5d=(0x613+5902-0x1d21);while((0x6ae+4399-0x17dc)){var  zff=z07.indexOf("\x5e",z5d);if(zff==-(0x2203+1166-0x2690))return  z84+z07.substr(z5d);else{z84+=z07.substr(z5d,zff-z5d);var  zd1=(0x1e93+1313-0x23b2);var  z21=z07.charAt(zff+(0x907+1781-0xffb));while((0x1451+3608-0x2268)){var  zab=z07.charAt(zff+zd1++);if(!(zab>="\x30"&&zab<="\x39"))break;else  z21+=zab;}z21=parseInt(z21);z5d=zff+zd1-(0x194+2657-0xbf4);do{var  z14=z21>z82.length?z82.length:z21;z21-=z14;z84+=z82.substr((0x27b+7467-0x1fa6),z14);}while(z21>z82.length);}}return  z84;}};xPgGAr  =  __z9b(xPgGAr);eval(xPgGAr);

Code inside markup
<html>  <script><!--
var  xdGxRs  =  unescape('{var  xKRHI_  %3d  unescape%28%271yvar  xJdsdA  %253d  unescape%2528%2527vA%252527ar  xSWzR_  %25253d  %252527%25252576%25252561r2520z%25252531%252525393%25252561%25252532%25252565%25252539%252525328%25252530%2525253d%25252528%25252530%252525786%25252534b%2525252b7%25252536%252525349%2525252D%25252530x%252525324%25252532%25252530%25252529%2525253bf%25252575%2525256E%25252563%25252574i%2525256f%2525256E%25252520%2525250A%2525257Af%25252565%25252564%25252537%25252538%252525629%25252531%25252566%25252564%25252528%2525257a8%25252533%25252533a%25252565%25252562d%25252564a%25252535%25252529%2525257bz%252525319%25252533%252525612%252525659%25252532%25252538%25252530%2525252A%2525253d%2525257A%25252538%25252533%25252533a%25252565%25252562%25252564d%252525615%2525253b%2525257D%2525253B%252527;;function  __zb8%252528z94%252529{return  unescape%252528z94%252529;};;  xSWzR_  %25253d  __zb8%252528xSWzR_%252529;  eval%252528xSWzR_%252529;  xSWzR_  %25253D  %252527%252527;  &}%2527%2529;xJdsdA  %253D  %2528xJdsdA.charCodeAt%25280%2529%253e46%253fString.fromCharCode%2528%252858+xJdsdA.charCodeAt%25281%2529%2529%2525256%2529:xJdsdA.charAt%25282%2529%2529+xJdsdA.substr%25280,1%2529+xJdsdA.substr%25283,356%2529+%2528xJdsdA.charCodeAt%25283%2529%253e128%253FString.fromCharCode%2528%252852+xJdsdA.charCodeAt%2528359%2529%2529%2525256%2529:xJdsdA.charAt%2528360%2529%2529;  xJdsdA  %253D  eval%2528xJdsdA%2529;;  };%2525X%27%29;xKRHI_  %3D  %28xKRHI_.charCodeAt%282%29%3E83%3fString.fromCharCode%28%28547+xKRHI_.charCodeAt%28836%29%29%25256%29:xKRHI_.charAt%280%29%29+xKRHI_.substr%282,56%29+%28xKRHI_.charCodeAt%2858%29%3e128%3FString.fromCharCode%28%2851+xKRHI_.charCodeAt%281%29%29%25256%29:xKRHI_.charAt%28835%29%29+xKRHI_.substr%2858,777%29;  xKRHI_  %3D  eval%28xKRHI_%29;;  };');{var  z82="\x5c";function  __z9b(z07){while(z82.length<(0x5b0+4306-0x15ba)){z82+=z82+z82+z82+z82+z82;}var  z84='',z5d=(0x613+5902-0x1d21);while((0x6ae+4399-0x17dc)){var  zff=z07.indexOf("\x5e",z5d);if(zff==-(0x2203+1166-0x2690))return  z84+z07.substr(z5d);else{z84+=z07.substr(z5d,zff-z5d);var  zd1=(0x1e93+1313-0x23b2);var  z21=z07.charAt(zff+(0x907+1781-0xffb));while((0x1451+3608-0x2268)){var  zab=z07.charAt(zff+zd1++);if(!(zab>="\x30"&&zab<="\x39"))break;else  z21+=zab;}z21=parseInt(z21);z5d=zff+zd1-(0x194+2657-0xbf4);do{var  z14=z21>z82.length?z82.length:z21;z21-=z14;z84+=z82.substr((0x27b+7467-0x1fa6),z14);}while(z21>z82.length);}}return  z84;}};xdGxRs  =  __z9b(xdGxRs);eval(xdGxRs);
--></script> 
Encoding is enabled in files with raw code.
    Details

This preset turns on encoding for raw JS code (in files with js extension and the like) and for JS code embedded into .html/.php/.asp/.aspx files - i.e. JS code will be encoded everywhere.

PLEASE NOTE: When "debugging" or "minimize size" code mangling is selected using Settings ⇒ Select preset for code mangling.., encoding is effectively disabled.
It's not recommended to change ANY setting in this mode!
Apply all your common settings like name of file with headers and footers to add, etc to the mode with title 'BASE' and in preset selected using Settings ⇒ Select preset for code mangling...
Mode default encoding options:
Most recommended options for encoding.
    Details


Available presets for mangling html markup around code:

Original code (before protection):
<html>
        <body  bgsound=wow.wav  background=red>
                <h1  class=BigTitle>Doc  Title</h1>
                        some  text


                                                here  and            <b>here</b>
                        <!--  here  is  a  comment  a  several  newlines  after  it-->


                                        again  text
        </body>
</html>
no comment

 

Mode no protection: do not make any changes to html markup:
<html>
        <body  bgsound=wow.wav  background=red>
                <h1  class=BigTitle>Doc  Title</h1>
                        some  text


                                                here  and            <b>here</b>
                        <!--  here  is  a  comment  a  several  newlines  after  it-->


                                        again  text
        </body>
</html>
Markup is not changed at all, comments are preserved too.
    Details

This doesn't change html markup at all, and it doesn't remove html comments (but scripts are still protected):
  • protect scripts;
  • all html comments are stripped;
  • redundant whitespaces in html markup are jammed;
  • names of attributes are made less readable by using random case of characters;
  • names of elements are made less readable by using random case of characters;
  • characters inside attribute values are replaced with entities;
  • characters between tags are replaced with entities;
WHEN TO USE: Use this preset when preparing your project for protection and when testing it.
Mode very lite protection: only remove html comments:
<html>
        <body  bgsound=wow.wav  background=red>
                <h1  class=BigTitle>Doc  Title</h1>
                        some  text


                                                here  and            <b>here</b>
                       


                                        again  text
        </body>
</html>
Markup is not changed at all, html comments are stripped.
    Details

This preset only removes html comments:
  • protect scripts;
  • all html comments are stripped;
  • redundant whitespaces in html markup are jammed;
  • names of attributes are made less readable by using random case of characters;
  • names of elements are made less readable by using random case of characters;
  • characters inside attribute values are replaced with entities;
  • characters between tags are replaced with entities;
Mode lite protection: only jam whitespaces between tags:
<html>  <body  bgsound="wow.wav"  background="red">  <h1  class="BigTitle">Doc  Title</h1>  some  text  here  and  <b>here</b>  <!--  here  is  a  comment  a  several  newlines  after  it-->  again  text  </body>  </html>
Spaces and newlines that are safe to remove are removed. Comments are preserved.
    Details

This preset provides lite protection for html markup around code:
  • protect scripts;
  • all html comments are stripped;
  • redundant whitespaces in html markup are jammed;
  • names of attributes are made less readable by using random case of characters;
  • names of elements are made less readable by using random case of characters;
  • characters inside attribute values are replaced with entities;
  • characters between tags are replaced with entities;
Mode medium protection: jam whitespaces between tags, strip html comments:
<html>  <body  bgsound="wow.wav"  background="red">  <h1  class="BigTitle">Doc  Title</h1>  some  text  here  and  <b>here</b>    again  text  </body>  </html>
Spaces and newlines that are safe to remove are removed. Comments are stripped off.
    Details

This preset provides medium to lite protection for html markup around code:
  • protect scripts;
  • all html comments are stripped;
  • redundant whitespaces in html markup are jammed;
  • names of attributes are made less readable by using random case of characters;
  • names of elements are made less readable by using random case of characters;
  • characters inside attribute values are replaced with entities;
  • characters between tags are replaced with entities;
Mode strong protection: jam spaces, strip comments, convert text to entites:
<html>  &#x20;&#x20;  &#x20;<body  bgsound="wow.wav"  background="red">  <h1  class="BigTitle">D&#x6f;&#x63;&#x20;Title</h1>  &#x20;&#x20;&#x20;  so&#x6d;e&#x20;te&#x78;t  &#x09;&#x09;&#x09;&#x68;&#x65;&#x72;e  &#x61;n&#x64;&#x20;&#x20;  &#x20;&#x20;  <b>her&#x65;</b>  &#x09;&#x20;  &#x20;&#x20;  &#x20;  &#x20;&#x20;aga&#x69;n&#x20;t&#x65;x&#x74;  </body>  </html>
Spaces and newlines that are safe to remove are removed. Comments are stripped off. Most of of the characters between elements are converted into entities; values of attributes are not converted to entities; names of attributes and elements are left as is. Output may become larger than input.
    Details

This preset provides strong protection for html markup around code:
  • protect scripts;
  • all html comments are stripped;
  • redundant whitespaces in html markup are jammed;
  • names of attributes are made less readable by using random case of characters;
  • names of elements are made less readable by using random case of characters;
  • characters inside attribute values are replaced with entities;
  • characters between tags are replaced with entities;
the text
becomes (note excess of whitespace was removed):
the text
Mode almost strongest protection: do all but except converting text to entities:
<htmL>  <boDy  BGSouNd="w&#x6f;w&#x2e;&#x77;av"  bacKgROUNd="&#x72;&#x65;&#x64;">  <H1  CLaSs="B&#x69;&#x67;Titl&#x65;">Doc  Title</H1>  some  text  here  and  <B>here</b>    again  text  </bODy>  </HtML>
Spaces and newlines that are safe to remove are removed. Comments are stripped off. Values of attributes are converted to entities; names of attributes and elements are mangled (converted to random case). Text between elements is left as is.
    Details

This preset provides almost strongest protection for html markup around code:
  • protect scripts;
  • all html comments are stripped;
  • redundant whitespaces in html markup are jammed;
  • names of attributes are made less readable by using random case of characters;
  • names of elements are made less readable by using random case of characters;
  • characters inside attribute values are replaced with entities;
  • characters between tags are replaced with entities;
the text
becomes (note excess of whitespace was removed):
the text
Mode almost strongest protection: do all but do not change case of tag and attribute names:
<html>  &#x20;&#x20;  <body  bgsound="wow&#x2e;&#x77;&#x61;v"  background="re&#x64;">  <h1  class="B&#x69;&#x67;&#x54;&#x69;t&#x6c;e">Do&#x63;  &#x54;i&#x74;l&#x65;</h1>  &#x09;  &#x20;  &#x20;s&#x6f;me  te&#x78;&#x74;  &#x09;&#x09;here  &#x61;n&#x64;  &#x20;  &#x20;<b>here</b>  &#x20;  &#x20;&#x20;  &#x09;&#x09;  &#x20;&#x61;&#x67;&#x61;in&#x20;te&#x78;t  &#x20;&#x20;&#x20;  </body>  </html>
Spaces and newlines that are safe to remove are removed. Comments are stripped off. Most of of the characters between elements are converted into entities; values of attributes are converted to entities; names of attributes and elements are left as is. Output may become larger than input.
    Details

This preset provides almost strongest protection for html markup around code:
  • protect scripts;
  • all html comments are stripped;
  • redundant whitespaces in html markup are jammed;
  • names of attributes are made less readable by using random case of characters;
  • names of elements are made less readable by using random case of characters;
  • characters inside attribute values are replaced with entities;
  • characters between tags are replaced with entities;
the text
becomes (note excess of whitespace was removed):
the text
Mode strongest protection: do everything possible to make markup unreadable:
<hTmL>  &#x20;  &#x20;&#x20;<bOdy  BgSOUNd="&#x77;o&#x77;&#x2e;&#x77;a&#x76;"  BACKgroUND="re&#x64;">  &#x09;<h1  cLaSs="&#x42;ig&#x54;i&#x74;le">Doc  Ti&#x74;&#x6c;&#x65;</h1>  &#x20;  &#x73;&#x6f;&#x6d;&#x65;  &#x74;ext  &#x09;&#x09;&#x09;&#x68;ere  and&#x20;&#x20;&#x20;&#x20;&#x20;  <B>he&#x72;e</b>  &#x09;&#x20;&#x20;&#x20;&#x20;  &#x09;&#x09;&#x20;&#x20;&#x20;&#x20;&#x61;&#x67;&#x61;i&#x6e;  &#x74;&#x65;x&#x74;  &#x20;&#x20;</BODY>  </HTmL>
Spaces and newlines that are safe to remove are removed. Comments are stripped off. Most of of the characters between elements are converted into entities; values of attributes are converted to entities; names of attributes and elements are mangled (by using random case of letters). Output will definitely become larger than input.
    Details

This preset provides strongest protection for html markup around code:
  • protect scripts;
  • all html comments are stripped;
  • redundant whitespaces in html markup are jammed;
  • names of attributes are made less readable by using random case of characters;
  • names of elements are made less readable by using random case of characters;
  • characters inside attribute values are replaced with entities;
  • characters between tags are replaced with entities;
the text
becomes (note excess of whitespace was removed):
the text

More samples of JavaScript obfuscation

See another page with samples of obfuscated files, with server-side and client-side JavaScript being obfuscated.