How Base64 works
Base64 turns binary data into 64 safe ASCII characters (A–Z, a–z, 0–9, + and /). Every 3 bytes of input become 4 characters, so encoded data is about 33% larger. When the input isn't a multiple of 3 bytes, one or two = signs pad the end.
Base64 is encoding, not encryption. Anyone can decode it, so never use it to hide passwords. It's used for email attachments (MIME), data URLs such as data:image/png;base64,…, HTTP Basic authentication headers and JSON Web Tokens.
UTF-8 and the £ sign
The browser's built-in btoa() fails on characters outside Latin-1, such as emoji. This tool converts text to UTF-8 bytes first, so "£" encodes as wqM= and emoji round-trip correctly. The URL-safe variant (RFC 4648 §5) swaps + and / for - and _, which JWTs and URLs use.
Frequently asked questions
Is Base64 secure?
No. It is a reversible encoding with no key. Anyone can decode it.
Why does my Base64 end in ==?
Padding: the input length wasn't a multiple of 3 bytes.
Can I decode Base64url here?
Yes. The decoder accepts - and _ and missing padding.
✨ New: Remove the background from any image free – private, in your browser, transparent PNG.
Related free tools
Note: This free tool runs entirely in your browser. No data is sent or stored. Results are for information only.