Base64 Decode
Decode Base64 into text or inspect the original bytes
Base64 decoding returns bytes, not necessarily text. The size and hex preview describe those exact bytes. A text preview appears only when the complete result is valid UTF-8. File detection is a convenience based on recognized signatures or parseable text; it is not a malware or file-safety scan.
This decoder checks the alphabet, padding position, encoded length, and unused bits in the final character. The options make whitespace and missing-padding behavior explicit, so a value is not silently accepted under rules you did not intend. Automatic detection reports ambiguity when the input uses only characters shared by Base64 and Base64URL.
Images, PDFs, archives, encrypted data, and compressed data commonly decode to bytes that are not UTF-8. That is a valid result, not a decode failure. Review the file-signature hint and hex bytes, then download the unchanged bytes if you need to open them with an appropriate local application.
Paste the complete data:...;base64,... value. The decoder separates the media type and parameters from the payload, decodes percent-escaped payload characters, and compares a recognized file signature with the declared media type. Non-Base64 data URIs should be handled with a URL decoder instead.
Use the command appropriate for your environment when the value should not be pasted into any website:
# Linux
printf '%s' 'SGVsbG8sIHdvcmxkIQ==' | base64 --decode # macOS
printf '%s' 'SGVsbG8sIHdvcmxkIQ==' | base64 -DPython can validate standard Base64 padding and characters explicitly:
import base64 decoded_bytes = base64.b64decode("SGVsbG8sIHdvcmxkIQ==", validate=True)
print(decoded_bytes)Why does valid Base64 have no readable output?
The decoded result may be binary data or text in an encoding other than UTF-8. Use the hex preview or download the bytes.
Can the tool prove what a binary file is?
No. A recognized signature is a useful format hint, but it does not validate the complete file or establish that the file is safe.
Does Base64 protect a secret?
No. Anyone who has the encoded value can decode it without a password or key.