Base64 Encode/Decode
Encode text to Base64 or decode it back, with full UTF-8 support for Chinese and emoji and a URL-safe option.
0 characters · 1 line
0 characters · 1 line
Shortcut: Ctrl/⌘ + Enter uses the result as input and switches mode
How to use
- Choose “Encode” or “Decode”.
- Paste or type into the input, or click “Example” to try it. The result updates instantly.
- When encoding, choose URL-safe output and whether to add = padding. Decoding detects both formats.
- Click “Use result as input” to convert the result back and check that it matches.
- Click “Copy” or “Download” to grab the result.
FAQ
Is my data uploaded?
No. Encoding and decoding happen in your browser. Your data never leaves your device, and the tool even works offline.
Is Base64 encryption?
No. Base64 only maps bytes to 64 printable characters. Anyone can decode it, so it does not protect passwords or secrets.
Why does my Chinese or emoji text encode differently elsewhere?
This tool always converts text to UTF-8 bytes first, which is the default on the web and in most programming languages. Tools that use another encoding, such as UTF-16 or Big5, give different results.
What is URL-safe Base64?
Standard Base64 uses + and /, which have special meanings in URLs. The URL-safe variant (base64url in RFC 4648) uses - and _ instead. It is common in JWTs and URL parameters and usually drops the trailing =.
Can I leave out the trailing =?
The = only pads the length to a multiple of 4 and carries no data. This tool decodes input with or without it, but some programs require it, so match what the receiving side expects when encoding.
Related tools
File to Base64
Convert images and any other file to Base64 or a Data URI, or turn Base64 back into a file to preview and download.URL Encode/Decode
Percent-encode or decode URLs and query parameters, with full UTF-8 support and exact error positions.Text to Hex
Convert text to UTF-8 bytes in hex or decode hex back to text, with strict UTF-8 validation that points at the bad byte.