Base64 to File Decoder

Decode Base64 to any file – the type is detected and the right extension is used.

Your files are processed on your device and are never uploaded.

Decode a Base64 string to any file. The tool reads the first bytes to work out what the file is – an image, PDF, ZIP, Word or Excel document, audio, video and more – and saves it with the right extension.

Base64 to File Decoder with ShrinkBee

Decoding runs in your browser, so the file inside the string never touches a server.

How to Convert Base64 to File

  1. Paste your Base64: Use Ctrl+V or the Paste button. A full data URI or just the plain string both work.
  2. Click Convert: The string is cleaned up and decoded.
  3. Check the result: You see a preview when the file is an image, PDF, sound, video or text, the detected type and the file size.
  4. Download: Save the file with the matching extension. Press Clear to start again.

Messy Strings Are Fixed for You

Base64 copied from logs, JSON, emails or URLs often has extra bits. The tool removes the data:…;base64, prefix, strips line breaks and spaces, converts URL-safe characters back, and corrects the = padding. A note lists what was changed. If the string cannot be decoded – for example because it is cut off – you get a clear explanation instead of a broken file.

How to Recognise What a String Holds

Many types can be spotted from the first characters: JVBERi0 is a PDF, UEsDBB a ZIP (Word .docx and Excel .xlsx files are ZIPs too), iVBORw0KGgo a PNG and /9j/ a JPG.

When the Type Cannot Be Detected

Plain text, CSV and some rarer formats have no fixed signature at the start. If the type is unknown, the file is saved with a .bin extension – rename it if you know what it should be. A data URI prefix, when present, is also used to pick the type.

Free, Private, No Upload

There is no sign-up and no limit on how many strings you decode. Because nothing is uploaded, it is safe for invoices, ID documents and other private files.

Base64 to Image Base64 to PDF Validator & Repair Base64 to Text Image to Base64 PDF to Base64

Frequently Asked Questions

How do I convert Base64 to file?
Paste the Base64 string or data URI into the box and click Convert. Check the preview and click Download to save a file.
Do I need the data:…;base64, prefix?
No. Both a full data URI and the plain Base64 string work. The prefix is removed automatically.
Why do I get an error when decoding?
The string may be cut off, contain characters that are not Base64, or include extra text such as JSON quotes or a field name. Copy only the encoded value. The Base64 Validator shows exactly what is wrong.
How is the file type detected?
From the first bytes of the decoded data, which are unique for most formats, and from the data URI prefix when there is one.
What if the file is saved as .bin?
The type could not be recognised. If you know what the file is, simply rename it with the right extension.
Is my data uploaded anywhere?
No. The string is decoded in your browser, and the file is created on your own device.
Is Base64 to File free to use?
Yes. Base64 to File is completely free, with no sign-up, no watermark and no limit on how many times you use it.
Are my files uploaded to a server?
No. Your files are processed directly in your web browser on your own device. Nothing is uploaded or stored, and the file is gone from memory when you close the tab.

More Base64 Tools

Made With ♥ By ShrinkBee