Base64 Encode/Decode
Encode text or images into Base64, or decode a Base64 string back to its original form.
Runs entirely in your browser, nothing is uploadedDrop an image here, or click to browse.
Encode or decode in three steps
- Choose encode or decode, and text or image mode.
- For text, type or paste directly. For images, upload a file to encode it.
- Copy the result, a Base64 string is safe to paste into HTML, CSS, JSON, or config files.
Why people use the Base64 Encode/Decode
Everything worth knowing before you dive in.
How it helps
Base64 turns binary or arbitrary text data into a string made only of letters, numbers, and a few symbols, which is why it shows up so often in places that only accept plain text, embedding a small image directly inside CSS, packing an API key into a config file, or passing data through a URL safely.
Built for real use
Text encoding and decoding here handles full Unicode correctly, so accented characters or emoji round trip without corruption, a common failure point in simpler Base64 tools. Image encoding reads the file directly in the browser and outputs a ready to use data URI that can be pasted straight into an img tag or CSS background property.
Private by default
Since everything happens client side, sensitive text or private images never leave your device during the conversion.
Pro tip
If a data URI you're decoding looks broken, check that the media type prefix, such as image/png or image/jpeg, actually matches the file you originally encoded, a mismatch is a common cause of a corrupted preview.
Common questions
Is Base64 encoding the same as encryption?
No, Base64 is not encryption or security of any kind, it's a reversible encoding anyone can decode. Don't use it to protect sensitive data.
Why does my image encoding include extra text at the start?
That's the data URI prefix, it tells a browser what type of file the following Base64 data represents, and is required for the string to work as an image source.
Can I decode a Base64 string back into a downloadable image?
Yes, paste a Base64 image string into decode mode and the tool will render it back as a viewable, downloadable image.