🇺🇸 English
🇪🇸 Español
🇧🇷 Português
🇫🇷 Français
🇩🇪 Deutsch
🇮🇹 Italiano
🇨🇳 中文
🇷🇺 Русский
🇯🇵 日本語
🇰🇷 한국어
🇳🇱 Nederlands
🇮🇳 हिन्दी

Base64 Decoder Online

Instantly decode Base64 strings or files back to their original format, right in your browser.

What is Base64 Decoding?

Base64 decoding is the reverse of Base64 encoding — it converts a Base64 string back into its original binary or text data. Given a valid Base64 string, any decoder can reconstruct the original data without any key or password, which is why Base64 is not a form of encryption.

Base64 encoded data is commonly encountered in JWT tokens (where header and payload are Base64URL encoded), email attachments transmitted via MIME, image Data URIs embedded in HTML and CSS, binary data returned by REST APIs in JSON responses, and configuration files that store binary values as text.

When decoding, it is important to know the original character encoding of the text data. If the original text was UTF-8 (the most common case), selecting UTF-8 or AUTO-DETECT will produce correct results. For legacy systems, you may need to select ISO-8859-1 or Windows-1252 to correctly decode accented characters and special symbols.

? Decodes each line of the input independently. Useful for multiple separate Base64 entries separated by line breaks.
LIVE
Invalid Base64 input. Please check your data and try again.

Decode a file from Base64

Drop your Base64 file here, or click to browse

Do not execute decoded files from untrusted sources.
Download decoded file

How to Decode Base64 Online

To decode a Base64 string with decodeb64.com, paste your encoded string into the input field and click Decode. The tool automatically strips whitespace and line breaks from the input before decoding, so you do not need to clean the string manually. The decoded output appears in the result field, ready to copy.

If you are decoding a Base64URL string (which uses - and _ instead of + and /), the tool handles this automatically — no manual replacement needed. If the character encoding of the original text is unknown, select AUTO-DETECT and the tool will attempt to identify the correct charset from the decoded bytes.

For batch decoding, enable the "Decode each line separately" option. Each line of your input will be decoded independently, which is useful when you have multiple Base64 entries separated by newlines, such as a list of encoded API tokens or identifiers.

Decode Base64URL and JWT Tokens

JWT (JSON Web Tokens) consist of three parts separated by dots: header.payload.signature. The header and payload are Base64URL encoded — not standard Base64. Base64URL uses - instead of + and _ instead of /, and omits the = padding character. Standard Base64 decoders will fail on JWT strings unless they handle this variant automatically.

decodeb64.com automatically detects and handles Base64URL input. To inspect a JWT token, paste the full token, then use the "Decode each line separately" option with a dot as the line separator — or simply paste just the header or payload portion (the text before the first or second dot).

Note that decoding a JWT payload reveals the claims it contains (user ID, expiration time, roles, etc.) but does not verify the signature. For security validation, always verify the JWT signature using the appropriate library for your programming language.

Decode Base64 Files and Binary Data

For encoded files, decodeb64.com includes a file decode section that accepts Base64-encoded .txt files. Upload the file containing the Base64 string, and the tool will decode it back to the original binary content. The file type is automatically detected from the decoded binary using magic byte signatures — PNG header bytes, JPEG SOI marker, GIF signature, WebP RIFF header, and others — so the downloaded file will have the correct extension.

This is useful for recovering files that were encoded for transmission in email or API responses, extracting images embedded as Base64 in configuration files, and decoding binary data stored in databases or log files as Base64 strings.

A security reminder: always verify the source of Base64 data before decoding and executing files. Base64 encoding is sometimes used to obfuscate malicious payloads. Never execute a decoded file from an untrusted source.

Frequently Asked Questions

What is Base64 decoding?
Base64 decoding is the reverse of encoding — it converts a Base64 string back to its original binary or text data. Used to recover data from JWT tokens, email attachments (MIME), API responses, and data URIs.
Is Base64 decoding the same as decryption?
No. Base64 is encoding, not encryption. Anyone can decode a Base64 string instantly — there is no key or password required. Never use Base64 alone to protect sensitive data.
What does "Invalid Base64 input" mean?
The input contains characters outside the Base64 alphabet (A–Z, a–z, 0–9, +, /, =). Common causes: extra whitespace, missing = padding, or the URL-safe variant (- and _ instead of + and /).
How do I decode a Base64URL string?
Base64URL replaces + with - and / with _ and removes = padding. Before decoding, replace - with +, _ with /, and add missing = padding so the length is a multiple of 4.
Can I decode binary files like images or PDFs?
Yes. Use the file decode section to upload a Base64-encoded .txt file. The tool decodes the binary content and offers it as a download with the correct file type detected automatically.
What is Base64 decoding?
Advanced options explained
Security & Privacy
Completely free
How Base64 works

Other Tools

Base64 Encode → Base64 to Image →