Tech / Base64 Encoder / Decoder
Base64 Encode & Decode
Encode and decode Base64 for text (full Unicode - any language and emoji) and files. Make image data URLs or turn Base64 back into a file - all in your browser.
Text
File → Base64
Pick any file (image, PDF, font...) to get its Base64 text or a data URL you can paste into HTML or CSS.
Base64 → File
About Base64
Base64 turns any data - text, images or files - into plain letters, numbers and the symbols + and /, so it can travel safely inside email, JSON or a web page. It is defined in RFC 4648. Every 3 bytes become 4 characters, so Base64 is about a third larger than the original. The = signs at the end are padding.
Is Base64 encryption?
No. Anyone can decode Base64 in seconds, so never use it to hide passwords or personal details. To keep data secret you need real encryption.
What is URL-safe Base64?
A version that uses - and _ instead of + and /, and often drops the padding, so the result can go in web addresses and file names. JSON Web Tokens use it. Tick "URL-safe" above to use it.
When is Base64 useful?
- Putting a small icon or image straight into HTML or CSS as a
data:address. - Sending a file through an API that only accepts JSON text.
- Email attachments, which are sent as Base64 behind the scenes.
For larger images, a normal image file is better, because Base64 makes the data about 33% bigger. Your text and files are encoded in your browser and are not uploaded.