Base64 Decode

Decode Base64 encoded strings back to plain text instantly — supports standard and URL-safe Base64.

What is Base64 Decoding?

Base64 decoding is the reverse of Base64 encoding — it converts a Base64-encoded string back to its original binary or text representation. Any Base64-encoded string can be decoded by anyone, making it important to understand that Base64 provides no security or privacy protection.

Common scenarios where you need to decode Base64 include: reading JWT token payloads to inspect claims and expiry times, decoding email attachments that were encoded in MIME format, extracting images from data URIs in HTML source code, decoding API responses that return binary data as Base64, and reading Basic Authentication credentials from HTTP headers.

This decoder handles both standard Base64 (using + and /) and URL-safe Base64 (using - and _). It also automatically strips whitespace and line breaks before decoding, so you can paste multi-line Base64 strings directly without manual cleanup. The output is decoded as UTF-8 text, supporting all Unicode characters.

If the Base64 input contains binary data (such as an image or PDF), the decoded output may appear as garbled characters in the text view. Use the Base64 to Image tool to properly decode and preview Base64-encoded images.

Frequently Asked Questions

How do I know if a string is Base64 encoded?
Base64 strings only contain characters A-Z, a-z, 0-9, +, / (or - and _ for URL-safe), and = for padding. The length is always a multiple of 4 (or 3 for URL-safe without padding). The string often ends with one or two = signs.
What does "Invalid Base64" mean?
It means the input contains characters that are not valid in Base64, has incorrect padding, or has a length that's not a multiple of 4. Common causes: the string was partially copied, URL encoding was applied on top of Base64, or the wrong variant (standard vs URL-safe) was used.
Can I decode a JWT token with this?
You can decode the individual parts of a JWT (header and payload are Base64url encoded). However, the dedicated JWT Decoder tool is better — it splits and decodes all three parts, formats the JSON, and shows expiry times automatically.
Why does my decoded output look like garbage?
The Base64 likely encodes binary data (an image, PDF, or other file) rather than text. Binary data displayed as text appears as garbled characters. Use the Base64 to Image tool if you expect an image, or download the raw output.