What is Base64?
Base64 is a way to write binary data with 64 plain text characters (A–Z, a–z, 0–9, + and /). You need it when binary data has to travel through a text-only channel: an image inside CSS, a file inside JSON, an email attachment, or a token in an HTTP header.
How to use the Base64 tool
- Pick Encode or Decode.
- Pick Text to type or paste, or File to upload a file (up to 10 MB).
- Read the result in the output pane. It updates as you type.
- Turn on URL-safe if the result goes into a URL or a file name.
- Click Copy or Download.
Why is the Base64 output larger?
Base64 writes every 3 bytes as 4 characters, so the output is about 33% larger than the input. A 300 KB image becomes about 400 KB of text. For this reason, Base64 suits small files such as icons, and not large photos.
URL-safe Base64 uses - and _ instead of + and /. JWTs use this form.
Frequently Asked Questions
Is Base64 encryption?
No. Base64 is an encoding, and anyone can decode it without a key. Do not use it to hide passwords or personal data.
Can I encode any file type to Base64?
Yes. Images, PDFs, audio and other binary files all work. Select File and upload a file of up to 10 MB.
What is URL-safe Base64?
URL-safe Base64 replaces + with - and / with _. The result can go into a URL or a file name without percent-encoding.
Why does the decoded result say it is binary data?
The Base64 string holds a file, not text, so it cannot show as readable characters. Click Download to save it as a file.
Does this tool send my data to a server?
No. Encoding and decoding run in your browser. Your text and files stay on your device.