Base64 to File

Decode Base64 or a Data URI into a downloadable file. Restore PDF, ZIP, images and text, inspect detected file types, and preserve the original bytes in your browser.

Decode
0 characters
Result

Your result will appear here.

How to decode Base64 into a file

  1. Paste the Base64 string, or a complete data:…;base64, URI, into the input field.
  2. Decode it and check the detected file type and size; supported images also have a preview.
  3. Download the restored file. If you have the original, compare its SHA-256 checksum to verify the bytes.

Working with Base64 to File

Download preserves every decoded byte. A recognised file signature determines the suggested extension. Unknown binary data is saved as .bin; rename it only when you know the actual file type.

Example: restoring a text file from Base64

Input
SGVsbG8sIHdvcmxkISDwn5GL
Result
result.txt (text/plain;charset=utf-8, 18 B) Hello, world! 👋

Questions about Base64 to File

Can I turn Base64 back into a PDF, ZIP or Word document?

Yes, if the Base64 contains that file's actual bytes. Decoding restores the data; it does not convert a different format into PDF or repair a damaged ZIP. Some Word documents use ZIP containers and may be offered as .zip. The original filename is not stored in plain Base64; change the suggested extension only if you know the true format.

Can I paste a Data URI or a Base64 value from JSON?

Both plain Base64 and a complete data:…;base64, URI work. For JSON, paste only the field's value, without the enclosing quotes or object. ASCII spaces and line breaks are ignored. Standard Base64 and Base64URL are accepted, but their alphabets must not be mixed.

Why is the download a .bin file, or why does decoding fail?

Unrecognised binary data is saved as .bin with MIME type application/octet-stream; this does not mean the bytes were lost. File signatures guide type detection, not the MIME label in a Data URI, and do not prove the file is intact. Invalid characters, misplaced = padding or incomplete data can cause errors. Percent-encoded text, HTML tags and escaped JSON line breaks must be extracted or decoded first.

What are the size limits, and is a decoded file safe to open?

The Base64 input limit is 48 MiB and the decoded file limit is 32 MiB. Decoding runs in your browser; Base64 is encoding, not encryption or a malware check. Download only files you trust. PDF and ZIP files are downloaded, not opened or unpacked by this tool.

Are my files, tokens or text uploaded?

No. These tools process your input in your browser. The website serves the page and its code, but your input is not sent to a conversion server or saved in an account.

  • File to Base64

    Encode any file to a Base64 string, with optional Data URI prefix, padding and MIME line wrapping.

  • Base64 to Image

    Decode a Base64 image or Data URI, preview supported image types and download the original image bytes.

  • SHA-256 Hash & File Checksum

    Generate SHA-256 hashes for text or files and check a downloaded file against its published checksum.

Explore all developer tools

Encoding & Files

Move between text, bytes, URLs and embedded images without changing your original data.

Data & Text Inspection

Read structured data, inspect tokens and understand exactly what changed.

Hashes, IDs & Schedules

Check file integrity, generate identifiers and make sense of times and recurring schedules.

Your input and files are processed on your device. Keep sensitive results out of shared clipboards and use a trusted device for private keys and tokens.