Base64 Decoder
Decode Base64 back to text, or recover the original file. URL-safe input and data URIs are handled automatically.
How to use the Base64 Decoder
- 1Paste the Base64 string, or a complete data URI.
- 2The decoded text appears immediately.
- 3If the data is binary, use the download button to save it as a file.
- 4Copy the text if that is what you needed.
How it works
Input is normalised before decoding: URL-safe characters are converted back, whitespace and line breaks are stripped, and missing padding is restored. That means a string copied out of a wrapped email header decodes without manual cleanup.
The decoded bytes are then examined. If they form valid UTF-8, the text is shown directly. If not, the data is binary, and the first bytes are checked against known file signatures to identify what it is — PNG, JPEG, PDF, ZIP and so on — so the download gets a sensible name and type.
Invalid Base64 is reported clearly. The most common causes are a truncated string, a mix of standard and URL-safe alphabets, or stray characters picked up during copying.
Everything runs in this page. Nothing you paste is transmitted, logged or stored, which is what makes it safe to drop a production payload in here while you are debugging.