Base64 Encoder & Decoder

Paste your text or Base64 string below and click the action button. Fully UTF-8 safe — supports emojis and international characters.

Encode to Base64
Plain text → Base64 string
Base64 Output
Output will appear here…
Decode from Base64
Base64 string → Plain text
Decoded Output
Output will appear here…

What Is Base64?

Base64 is a binary-to-text encoding scheme that represents binary data using a set of 64 printable ASCII characters: A–Z, a–z, 0–9, +, and /, plus = for padding. It was originally designed to safely transmit binary content over systems that were designed to handle only text.

Each group of three bytes (24 bits) of input is converted into four Base64 characters. Because 64 = 2⁶, each character encodes exactly 6 bits. This means Base64 output is always approximately 33% larger than the original binary input, but the result contains only safe, printable characters that survive transport through virtually any system.

Base64 is not encryption — it provides no confidentiality whatsoever. Anyone who sees a Base64 string can trivially decode it. It is purely an encoding mechanism for compatibility, not security.

Common Use Cases

Base64 encoding is used extensively throughout modern software development, networking, and web standards:

Data URLs
Embed images, fonts, or files directly inside HTML/CSS as data:image/png;base64,… URIs, eliminating extra HTTP requests.
API Authentication
HTTP Basic Authentication encodes credentials as Base64(username:password) in the Authorization header.
Email MIME
SMTP email standards (RFC 2045) use Base64 to encode binary attachments so they can travel safely through email relay servers.
Binary Transport
JSON and XML cannot carry raw binary. APIs encode binary blobs (certificates, keys, files) as Base64 strings for safe serialization.

Frequently Asked Questions

No. Base64 is encoding, not encryption. It simply converts binary data to a text-safe format using a fixed, publicly known algorithm. Anyone can instantly decode any Base64 string — there is no key, no secret, and no confidentiality. Never use Base64 as a security measure. For real security, use authenticated encryption (AES-GCM, ChaCha20-Poly1305) with a proper key management system.
Base64 encodes 3 bytes at a time into 4 characters. When the input length is not a multiple of 3, the final group is padded with one or two = signs to make the output length a clean multiple of 4. One = means 1 byte of padding was added (2 input bytes in the final group). Two == means 2 bytes of padding (only 1 input byte in the final group). No padding means the input was an exact multiple of 3 bytes.
Yes — when encoded correctly. Base64 operates on raw bytes, not characters. This tool first converts your text to its UTF-8 byte representation before applying Base64 encoding. This means emojis (e.g. 😀), Arabic, Chinese, Japanese, accented Latin characters, and any other Unicode text are all handled correctly. When decoding, the tool reverses this process: Base64 bytes → UTF-8 bytes → Unicode text.
Standard Base64 uses + and / which have special meaning in URLs and file paths. Base64URL is a variant (defined in RFC 4648) that replaces + with - and / with _, and omits padding. This makes the output safe for use in URL query strings, cookie values, and filenames without percent-encoding. JWTs (JSON Web Tokens) use Base64URL encoding.
All encoding and decoding happens entirely in your browser using JavaScript. Your input is never sent to any server — there is no backend, no analytics on your content, and no logging of what you encode or decode. You can even download this page and run it offline.