The Base64 Encoder / Decoder converts text to Base64 and back again. Type or paste your text to encode it, or paste Base64 to decode it to readable text. It fully supports Unicode, so emoji and non-English characters encode and decode correctly, and it offers a URL-safe option for use in links and filenames.
You can also convert any file — an image, PDF, or font — into a Base64 data URI that you can paste directly into HTML, CSS, or code. Everything happens in your browser, so your text and files are never uploaded.
How to encode and decode Base64
- Choose Encode or Decode.
- Type or paste your text (or Base64) into the input box.
- Copy the result from the output box. Use “Swap” to reverse the direction quickly.
- To encode a file, use “File to Base64” and choose a file to get its data URI.
What is Base64?
Base64 is a way of representing binary data (or text) using only 64 printable ASCII characters: A–Z, a–z, 0–9, plus “+” and “/”. It is widely used to safely embed or transmit data through systems that only handle text, such as email, JSON, and data URIs in web pages.
Base64 is an encoding, not encryption — it does not protect or hide data, it only reformats it. Anyone can decode it back to the original.
When to use Base64
- Embedding small images or fonts directly in HTML/CSS as data URIs.
- Sending binary data inside JSON or XML payloads.
- Encoding attachments in email (MIME).
- Storing or transmitting data through text-only channels.
- URL-safe Base64 for tokens, query parameters, and filenames.
Frequently Asked Questions
What is the difference between encoding and decoding?
Encoding converts your original text or file into Base64 characters. Decoding takes Base64 and converts it back to the original text. Use the Encode/Decode toggle to switch.
Does this support emoji and non-English text?
Yes. It encodes text as UTF-8 before converting to Base64, so emoji, accented characters, and non-Latin scripts are handled correctly in both directions.
What is URL-safe Base64?
URL-safe Base64 replaces the “+” and “/” characters with “-” and “_” and removes padding, so the result can be used safely in URLs, query strings, and filenames. Tick the “URL-safe output” box when encoding.
Is Base64 the same as encryption?
No. Base64 is an encoding scheme, not encryption. It does not secure your data — anyone can decode it. Do not use it to protect sensitive information.
Is my data private?
Yes. All encoding and decoding, including files, happens locally in your browser. Nothing is uploaded to a server.