Base64 Encoder & Decoder

Convert text to Base64 and back, or turn a file into a data URI — with proper UTF-8 handling for emoji and accents.

🔒 Runs entirely in your browser — nothing is uploaded

What is Base64, and why use it?

Base64 turns any data — text, images, files — into a plain string of safe ASCII characters that survives email, JSON, URLs and copy-paste without getting mangled.

1

Encode

Paste text to get its Base64 form. Emoji and accented characters are handled correctly through UTF-8 — no garbled output.

2

Decode

Paste a Base64 string to read the original text back. Whitespace and URL-safe variants are accepted automatically.

3

File → data URI

Drop in an image or small file to get a data: URI you can embed directly in HTML or CSS.

🔒

Private by design. Every conversion happens right here in your browser using built-in JavaScript. Your text and files are never sent anywhere — we never see them.

Frequently Asked Questions

What is Base64 encoding used for?
Base64 turns any data into a plain string of safe letters, numbers and a few symbols. It's used to embed images in HTML or CSS, attach files in email, and carry binary data inside JSON, URLs or config files without it getting corrupted.
Does it handle emoji and accented characters correctly?
Yes. Text is processed as UTF-8, so emoji, accents and non-Latin scripts encode and decode back exactly as you typed them — no garbled output.
What is URL-safe Base64?
Standard Base64 uses + and /, which have special meaning in web addresses. The URL-safe option swaps them for - and _ and drops the trailing = padding, so the result can be dropped straight into a link.
Why does decoding say my Base64 is invalid?
Usually the string is truncated or contains stray characters that aren't part of the Base64 alphabet. Extra spaces and line breaks are fine — those are ignored automatically — but a cut-off string can't be decoded.
What is a data URI, and when would I use one?
A data URI is a data: string that contains a whole file inline. It's handy for embedding a small image directly in HTML or CSS so it loads without a separate request.
Is my text or file uploaded anywhere?
No. Every conversion happens entirely in your browser on your own device. Nothing you type or drop in is ever uploaded, and we never see it.