What it does
Base64 turns bytes into 64 printable characters so binary data can travel through JSON, HTTP headers, email and config files. This tool converts in both directions as you type.
- UTF-8 safe: text is encoded as UTF-8 bytes first, so
ü,İand emoji round-trip correctly (plainbtoa()fails on them). - URL-safe and unpadded output (
-and_instead of+and/, no trailing=), the variant used by JWTs and many URLs. - Wrap at 76 produces MIME / PEM style lines.
- Forgiving decoder: line breaks, spaces, missing padding, the URL-safe alphabet and a
data:URI prefix are all accepted. Real errors are reported with the exact line and column. - Binary aware: if the decoded bytes are not valid UTF-8, a hex dump is shown instead of garbled text, and the file type is detected from its magic bytes.
- Files: drop any file to get its Base64, or use Save as file to turn Base64 back into a file with the right extension.
How to use it
- Pick Encode or Decode.
- Type, paste or drop a file into the left pane. The result updates immediately.
- Press Copy (or Ctrl+Enter) or Download. Swap feeds the output back in and flips the direction.
Privacy
Everything happens in your browser. Files are read locally and nothing is uploaded. Your last text input and options are kept in your browser’s local storage; Clear removes the input.