Base64 encode/decode
Encode or decode text as base64.
Base64 encode/decode converts plain text to its base64-encoded representation, or decodes a base64 string back to plain text, updating automatically as you type.
How to use
- Choose Encode or Decode.
- Paste your input — the result updates automatically.
Common use scenarios
- Encoding a string for use in a context that requires base64, like some API payloads or config values.
- Decoding a base64 string found in a log, token, or config file to see its actual content.
- Encoding credentials or data for a Basic Auth header (understanding it's encoding, not encryption).
- Quickly checking what a base64-encoded value actually says without writing code.
✓Content & verification reviewed: 2026-08-25
How we verify Base64 encode/decode
How to confirm the encode/decode result is correct and complete.
Round-trip check
Encode some text, then paste the result into Decode mode — you should get back exactly your original text. This is a quick way to confirm the tool (and your understanding of the data) is working as expected.
Base64 is encoding, not encryption
Base64 is a reversible text representation, not a security measure — anyone can decode it back to the original text instantly, so never rely on it to actually protect sensitive data like passwords.
Decoding requires standard base64 input
If your input uses a variant like base64url (which replaces some characters for URL-safety) or has been altered/truncated, standard decoding may fail or produce garbled output — the tool shows an error rather than guessing at malformed input.
Before you rely on the result
- You've confirmed which mode (Encode or Decode) you actually need before pasting input.
- You understand base64 is not encryption — it doesn't protect sensitive data from anyone who sees it.
- If decoding fails, you've checked whether the source might be base64url or another variant instead of standard base64.
- You've verified a round-trip (encode then decode) matches your original text, if you want extra confidence.
Who this is for
- Developers encoding or decoding values for API payloads, tokens, or config files.
- Anyone who found a base64 string in a log or file and wants to see what it actually contains.
- Developers building a Basic Auth header who understand it's encoding, not real security.
- Anyone who wants a quick way to encode/decode text without writing a script.
Real-world examples
Decoding a value found in a log file
A developer spots a base64-encoded string in an application log and decodes it to quickly see the underlying data without writing a one-off script.
Encoding a value for an API payload
Someone needs to send binary-safe text data as part of a JSON API payload that requires base64 encoding, and encodes it directly before pasting into their request.
Building a Basic Auth header manually
A developer testing an API manually constructs a Basic Auth header by encoding "username:password" as base64, understanding this is a standard format, not encryption.
Limitations
- Decoding requires standard base64 input; other encodings (base64url, etc.) aren't auto-detected.
Frequently asked questions
Is base64 encoding secure? Can I use it to protect passwords?
No — base64 is just a reversible text representation, not encryption. Anyone can decode it instantly, so it provides no real protection for sensitive data.
Why did decoding fail on my base64-looking string?
It might be a variant like base64url (which uses different characters for URL safety) rather than standard base64, or the string may have been truncated or altered — standard decoding expects properly-formed standard base64 input.
Does encoding work with any text, including emoji or non-English characters?
Yes — the encoder handles standard Unicode text, converting it to its UTF-8 byte representation before base64-encoding it.
What's the difference between base64 and base64url?
Base64url replaces two characters (+ and /) that aren't URL-safe with URL-safe alternatives (- and _), and often omits padding — if your source explicitly used base64url, standard base64 decoding may not work directly on it.
🔒 Runs in your browser — nothing is uploaded. Results are for reference only; see the disclaimer. Last updated: 2026-08-25
Subscribe for updates
New tools and tips, straight to your inbox. No spam, unsubscribe anytime.