Base64 Encoder and Decoder for Text and Files
Convert text to Base64 and back, or turn an image or file into a Base64 data URL for HTML, CSS or an API.
- Works on your device. Nothing is uploaded.
- Free, no watermark
- No signup
How to use
- Choose Encode or Decode.
- Type or paste text, or open a file to encode it.
- Copy the result, or download a decoded file.
Good to know
Text is converted to UTF-8 bytes first, so Hindi, ₹ and emoji encode and decode correctly (many simple tools break them). "URL-safe" uses - and _ instead of + and / and drops the = padding, as used in JWTs and web addresses.
Opening a file encodes its exact bytes. With "data: URL prefix" on you get a ready-to-use value such as data:image/png;base64,… for an <img> tag or CSS background. Base64 makes data about 33% larger, so it suits small icons, not big photos.
When decoding, the tool accepts standard or URL-safe Base64, with or without padding and line breaks, and also full data: URLs. If the result is not text (for example an image or PDF), it shows the file type and size and lets you download it. Base64 is an encoding, not encryption: anyone can decode it.
Questions
Is Base64 encryption?
No. It only changes how data is written. Never use it to hide passwords.
Why does my Hindi text decode wrongly elsewhere?
The other tool probably did not use UTF-8. This one does, for both directions.
How do I turn an image into Base64?
Choose Encode and open the image; you get a data: URL you can paste into HTML or CSS.
Can I decode Base64 back into an image?
Yes. Paste it in Decode mode; images show a preview and can be downloaded.
Are my files uploaded?
No. Files are read and encoded in your browser.