Decode Base64 to File

Decode standard, URL-safe, unpadded, IMAP-style, or custom-alphabet Base64 data into a downloadable file online. Read more

Decode Base64 to a file

This tool converts Base64 text back into binary bytes and downloads the result using the filename you provide. You can paste the encoded text, load it from a local text file, or fetch it from a URL.

Base64 is an encoding rather than encryption. Decoding does not validate whether the resulting file is safe, authentic, or appropriate for its filename extension. Standard Base64 and Base64URL are defined in RFC 4648.

How to restore a Base64 file

  1. Paste or load the complete Base64 text.
  2. Enter the desired output filename, including an extension when needed.
  3. Select Standard for common standard, URL-safe, unpadded, MIME-wrapped, or IMAP-style input. Select Custom when the source uses another 64-character alphabet.
  4. Decode and download the resulting bytes.

The filename controls how the downloaded file is named; it does not convert the underlying format. For example, naming arbitrary bytes image.png does not make them a valid PNG image.

Common decoding problems

Base64 input may fail or produce unexpected bytes when it is truncated, uses the wrong custom alphabet, contains invalid characters, or has malformed padding. The Standard decoder accepts CR/LF line breaks and omitted trailing padding. It does not interpret MIME headers or other surrounding protocol text.

If the source is a complete data URL such as data:image/png;base64,..., remove the metadata prefix unless the input handler explicitly expects it. The Base64 payload begins after the comma.

Base64 file FAQ

How can I check that the decoded file is unchanged?

Compare a trusted checksum of the original file with a checksum calculated after decoding. Encoding and decoding correctly should preserve every byte.

Is it safe to decode unknown Base64?

Base64 text can represent any file type, including executable or malicious content. Treat decoded files with the same caution as any untrusted download.

How do I encode a file?

Use the File to Base64 tool to convert local or URL content into Base64 text. Use Base64 Decode when the result should be displayed as text instead of downloaded.

Input
File
Drag and drop the file here, click to select, or paste from the clipboard. It will process locally and won't be uploaded.
Output
Settings