Base64 Encoder & Decoder
Turn any text into Base64, or decode a Base64 string back into plain text. It handles emoji and non-English characters correctly, supports URL-safe Base64, and shows results live as you type.
Choose Encode or Decode, paste your text, and the result appears instantly. Use Swap to reverse the result, then Copy it.
What is the Base64 Encoder & Decoder?
Base64 is a way of writing any data using only 64 safe characters (A–Z, a–z, 0–9, + and /). This tool converts normal text into Base64 and converts Base64 back into readable text.
What does this tool do?
In Encode mode it turns your text into UTF-8 bytes and writes them as Base64, so emoji and languages like Hindi, Urdu or Arabic survive the round trip. In Decode mode it accepts standard or URL-safe Base64, ignores spaces and line breaks, adds missing padding, and tells you clearly when the input is invalid or is binary data rather than text.
How to use the Base64 Encoder & Decoder
- Pick Encode or Decode at the top.
- Type or paste your text or Base64 into the input box — the result updates as you type.
- For tokens and web addresses, switch on URL-safe to use - and _ without = padding.
- Press Swap to send the result back into the input and reverse the direction.
- Press Copy to copy the result, or Clear to start again.
Key features
Live results
Output updates on every keystroke, no button needed.
Full Unicode support
Text is encoded as UTF-8, so emoji and every language decode back exactly.
URL-safe mode
Produces Base64URL (- and _, no padding) used in JWTs and web addresses.
Forgiving decoder
Accepts URL-safe input, spaces, line breaks and missing padding.
Clear error messages
Explains whether the input has invalid characters or is a binary file.
Runs locally
Nothing you paste is uploaded.
Benefits
- Avoid broken characters when encoding non-English text.
- Debug tokens and API data without installing anything.
- Switch between encoding and decoding in one click.
Practical examples
Simple text
'Hello, World!' encodes to 'SGVsbG8sIFdvcmxkIQ=='.
Reading a JWT
Paste the middle part of a JSON Web Token in Decode mode to read its JSON payload (the signature is not checked).
Basic auth header
Encode 'user:password' to build the value used after 'Basic ' in an HTTP Authorization header.
Who should use this tool?
- Web and app developers
- QA testers and support engineers
- Students learning about encodings
- Anyone who received a Base64 string and wants to read it
Common use cases
- Inspecting API responses and JWT payloads
- Building HTTP Basic authentication headers
- Embedding small data in JSON, XML or config files
- Decoding Base64 text found in emails or logs
- Preparing URL-safe tokens
Important limitations
- Base64 is encoding, not encryption — anyone can decode it, so never use it to hide passwords.
- This tool works with text. Base64 that contains images or other files is detected but not displayed.
- Encoded output is about 33% larger than the original text.
- Very large inputs depend on your device memory.
Frequently asked questions
What is Base64 used for?
+
It lets binary or special-character data travel safely through systems that only handle plain text, such as email, JSON, URLs and HTTP headers.
Is Base64 encryption?
+
No. Base64 is reversible by anyone and gives no security. Use real encryption to protect sensitive data.
What is URL-safe Base64?
+
A variant that replaces + with - and / with _, and usually drops the = padding, so the result can be used in web addresses and file names. JWTs use it.
Why does my decoded text show an error about binary data?
+
The Base64 probably contains a file such as an image or PDF rather than text, so it cannot be shown as readable characters.
Does it support emoji and other languages?
+
Yes. Text is encoded as UTF-8, so emoji and scripts like Hindi, Urdu, Arabic and Chinese decode back exactly.
Related tools
JSON Formatter and Validator
Beautify, minify and validate JSON with clear error messages pointing to the exact line and column.
Word Counter
Count words, characters, sentences and paragraphs as you type, with an estimated reading time.
Case Converter
Switch text between UPPERCASE, lowercase, Title Case and Sentence case in one click.
Page Size Checker
Check how heavy any web page is. See the total size, the largest files and what is slowing it down.
Alt Code Check Mark
Find every check mark, tick and cross symbol with its Alt code, Unicode and HTML entity. Click any symbol to copy it instantly.