About Encoding Tool
Three encodings account for almost all day-to-day work: Base64 for getting binary through text-only channels, percent-encoding for putting values safely into URLs, and HTML entities for writing characters into markup without breaking it. They solve different problems and are constantly confused for one another, so having them side by side makes the difference obvious.
Every conversion here handles Unicode correctly by going through UTF-8 bytes. The naive implementations — bare btoa and atob — throw or corrupt data on anything outside Latin-1, which means emoji, accented characters and every non-Latin script. That bug is invisible until someone pastes a name with an accent in it.
None of these is encryption. All three are fully reversible with no key and no secret, and treating Base64 as though it hides something is a recurring source of real vulnerabilities. A JWT payload is plain Base64 and readable by anyone holding the token.
How to encode or decode
Choose an encoding
Base64, URL percent-encoding or HTML entities.
Pick a direction
Encode from plain text, or decode back to it.
Set any options
URL-safe Base64, line wrapping, or which of the three URL encoding modes you need.
Copy the result
The output updates as you type. Copy it or download it as a file.
The three URL encoding modes
- Component — escapes everything unsafe, including / ? : @ & = +. Use it for the value of a single query parameter.
- Full URI — leaves the characters that structure a URL alone, so a complete address stays usable. Use it to encode a whole URL.
- Form — the application/x-www-form-urlencoded convention, where a space becomes + rather than %20.
Standard and URL-safe Base64
Standard Base64 uses + and / as its final two characters, plus = for padding. All three have special meaning in a URL: + can be read as a space, / is a path separator, and = separates a parameter from its value.
URL-safe Base64 substitutes - for + and _ for /, and usually drops the padding. Use it for anything appearing in a URL path, a query parameter or a filename. Decoding detects which variant you have automatically.