Base64 to Text
Decode Base64 to UTF-8 in the browser with atob: missing = padding restored, base64url - and _ handled, MIME line breaks and data: headers stripped.
Still loading. If the tool doesn’t appear, reload this page.
About this tool
Base64 to Text
Decode Base64 strings into readable UTF-8 text, with padding repair, URL-safe alphabet support and a validity check.
Base64 to Text converts a Base64 string back into the characters it encodes, using the standard alphabet from RFC 4648 §4 and — once URL-safe Base64 support is ticked — the URL-safe variant from §5. It repairs missing `=` padding, strips the line breaks that MIME Base64 inserts every 76 characters, unwraps a leading data: URL header, decodes the bytes as UTF-8, and names the check that failed when a string is rejected. It is for developers reading a JWT payload, a webhook body, an HTTP Basic header or a config value that arrived encoded.
How to use Base64 to Text
Load the string into the 'Base64 Encoded Input' box — type it, press Paste, press Upload .txt (it accepts .txt, .b64 and .base64), drop a file onto the box, or press Sample Data. Clear empties the box and the character count sits beneath it.
Auto Decode is ON by default, so the 'Decoded Text Output' panel updates as you type; switch it off and press Decode to run it by hand. Advanced Options holds 'Preserve line breaks', 'Trim whitespace', 'Detect invalid Base64' and 'URL-safe Base64 support' — turn the last one on when the payload uses - and _ characters.
Press Copy, Download .txt (saved as decoded-text.txt) or Share to take the text away; the Input Size, Output Size, Decoding Status and Processing Time tiles describe the last run, and Reset All returns the tool to its defaults.
Why use Base64 to Text
Padding fixed automatically
JWT and URL-safe payloads drop the `=` characters; this tool restores them instead of failing.
Says why the input failed
Detect invalid Base64 catches a 4n+1 length, characters outside the alphabet, and URL-safe - or _ while that option is off, printing the reason under the input box.
Nothing is transmitted
Tokens and secrets are decoded locally with the browser's own `atob`, so they never reach a server or a log.
Common use cases
- Read the claims inside the middle segment of a JWT — tick URL-safe Base64 support first, because that segment uses - and _ with the padding stripped
- Decode an `Authorization: Basic` header to confirm which username a failing integration is actually sending
- Check what a Base64 value in a Kubernetes Secret or a CI environment variable really contains before rotating it
Frequently asked questions
How do I decode a Base64 string to text?
Paste it into the box and the plain text appears instantly — no upload and no sign-in. Decoding is reversible and takes no key: Base64 is an encoding, so anyone holding the string can read it, which is why it must never be used to protect a password.
Link to answerWhy does my JWT fail in other Base64 decoders?
Because JWTs use base64url (RFC 4648 §5): `+` becomes `-`, `/` becomes `_`, and the trailing `=` padding is removed entirely, as required by RFC 7515 §2. A decoder expecting standard Base64 rejects that. This tool always re-adds the 1 or 2 padding characters, and converts the alphabet once URL-safe Base64 support is on — leave it off and it stops with “URL-safe characters (- _) detected”.
Link to answerIs Base64 the same as encryption?
No. Base64 provides zero confidentiality — it is a reversible mapping of 3 bytes onto 4 printable characters, designed in RFC 4648 so binary data can survive text-only channels like email headers. Anyone can decode it in a second. Use AES or an equivalent cipher when the data actually needs protecting.
Link to answerHow many bytes does a Base64 string decode to?
Take the character count, divide by 4, multiply by 3, then subtract the number of `=` padding characters. A 24-character string ending in `==` decodes to 24 ÷ 4 × 3 − 2 = 16 bytes. That 4:3 ratio is why Base64 always costs about 33% more space than the raw data.
Link to answerEmbed this tool on your site
Add the Base64 to Text widget to your blog or website — free, responsive, no signup. Just keep the “Widget by AltFTool” credit link visible.
<iframe src="https://www.altftool.com/embed/widget/base64-to-text"
title="Base64 to Text — free AltFTool widget"
width="100%" height="640" style="border:0;border-radius:12px;overflow:hidden"
loading="lazy" referrerpolicy="no-referrer-when-downgrade" allow="clipboard-write"></iframe>
<p style="font-size:12px;margin:4px 0 0">Widget by <a href="https://www.altftool.com/tools/all/base64-to-text?utm_source=embed&utm_medium=widget" rel="nofollow">AltFTool — free online tools</a></p>