Base64 Encoder / Decoder
Convert text to Base64 and back. Full UTF-8 support, so emoji and non-Latin scripts round-trip correctly.
What is Base64?
Base64 is a way to represent binary data using 64 printable ASCII characters. Every three input bytes become four output characters, so the encoded result is about 33% larger than the original. It exists because many systems โ email, JSON, URLs, HTML attributes โ were designed to carry text, not raw bytes.
Base64 is encoding, not encryption
This is the single most important thing to understand: anyone can decode Base64 in a second. It provides no confidentiality whatsoever. Never use it to "hide" a password, an API key, or personal data. If you need secrecy, use encryption (AES-GCM) and keep the key separate from the ciphertext.
Why some decoders mangle emoji
Many older tools call btoa() directly on a JavaScript string, which only handles characters in the Latin-1 range. Emoji, Chinese, Arabic and accented characters then throw an error or come out garbled. This page converts the string to UTF-8 bytes first, so any Unicode text round-trips exactly.
Typical uses
- Embedding small images inline in CSS or HTML as data URIs.
- Sending binary attachments through JSON APIs.
- Basic authentication headers โ again, encoding only, always over HTTPS.
- Storing binary blobs in systems that only accept text.