Converters

Base64

Encode / decode text, files & images

PLAIN TEXT
BASE64

This free online Base64 encoder and decoder converts text, files, and images to and from Base64 entirely in your browser — nothing is uploaded to a server. Base64 is a binary-to-text encoding scheme that represents arbitrary bytes using only 64 printable ASCII characters (A–Z, a–z, 0–9, +, /), which makes it safe to embed binary data — images, fonts, small files — inside text-based formats like JSON, XML, CSS data URIs, or email (MIME) attachments. Paste a string to encode or decode instantly, or drop in a file/image to get a ready-to-use Base64 string or data URI. Because everything runs client-side with the Web `btoa`/`atob` and `FileReader` APIs, your data never leaves the tab — useful for encoding sensitive tokens, API keys, or private files without a third-party service seeing the plaintext.

FAQ

Is Base64 encoding the same as encryption?

No. Base64 only re-represents bytes as text — it provides zero confidentiality. Anyone can decode a Base64 string back to its original bytes instantly, with no key required. Use actual encryption (e.g. AES) if you need to protect data, and only use Base64 for safely transporting binary data through text-only channels.

Why does my Base64 string end with one or two = signs?

Base64 encodes 3 bytes of input into 4 output characters. When the input length isn't a multiple of 3, the last group is padded with `=` characters so the output length stays a multiple of 4. One `=` means the input had 2 bytes left over; two `==` means 1 byte was left over. Padding is optional in some URL-safe variants but standard Base64 includes it.

Why is the Base64 output longer than the original file?

Base64 has roughly a 33% size overhead because it packs 3 bytes of binary data into 4 text characters (8 bits → 6 usable bits per character). A 300 KB image becomes roughly 400 KB once Base64-encoded — expected behavior, not a bug.

Can I decode a Base64 image straight into a usable picture?

Yes — decode it here and the tool renders the result as an image preview automatically when the bytes are a valid image format (PNG, JPEG, WebP, GIF), so you can verify the decode visually before downloading.