Base64 Encoder & Decoder
Encode text to Base64 or decode Base64 to text — free, private, and instant in your browser.
How to Use the Base64 Encoder & Decoder
- Paste plain text to encode, or paste a Base64 string to decode, into the input box.
- Optionally enable "URL-safe Base64" when you need Base64URL characters (- and _) instead of + and /.
- Click "Encode" to convert text to Base64, or "Decode" to restore the original text.
- Use "Copy result" to copy the output, or "Clear" to start over.
What Is a Base64 Encoder and Decoder?
Base64 encoding turns binary or text data into a safe ASCII string using A–Z, a–z, 0–9, +, and /. Developers use it to embed images in HTML/CSS, put binary payloads in JSON, and pass data in URLs or emails that only allow text.
This free Base64 encoder and decoder runs entirely in your browser with UTF-8 support, so accents, emoji, and other non-ASCII characters encode and decode correctly. Nothing you type is uploaded or stored on a server.
Need related developer utilities? Try the hash generator, UUID generator, or JSON editor.
Frequently Asked Questions (FAQ)
What is Base64 encoding?
Base64 encoding converts binary data (or text) into a text format using 64 printable characters so it can be safely transmitted or stored in systems that expect ASCII text.
How do I encode a string to Base64?
Enter your text in the input box and click "Encode". The tool instantly converts it to Base64. Enable URL-safe mode if you need Base64URL output for URLs or JWTs.
How do I decode a Base64 string?
Paste the Base64 string, click "Decode", and the original UTF-8 text is restored. If decoding fails, the input is not valid Base64.
Does this tool support UTF-8 and special characters?
Yes. Encoding and decoding use UTF-8, so accents, emoji, and other Unicode characters work correctly — important for Spanish, French, and other non-ASCII text.
What is URL-safe Base64 (Base64URL)?
URL-safe Base64 replaces + with - and / with _ so the string can appear in URLs and filenames without extra escaping. Optional padding (=) may be omitted depending on the consumer (for example JWT payloads).
Is Base64 encoding secure for passwords?
No. Base64 is encoding, not encryption. Anyone can decode it. Use a proper password hash or encryption for secrets — Base64 alone does not protect data.
Is my text private?
Yes. All encoding and decoding runs in your browser. ToolGenie does not upload, store, or share the text you enter on this page.
Tips for Using Base64 Encoding
- Tip 1: Use URL-safe mode when putting Base64 in query strings, path segments, or JWT-style tokens.
- Tip 2: Remember Base64 is not encryption — never treat encoded passwords or API keys as secret.
- Tip 3: If decode fails, remove spaces/newlines or confirm the string uses standard (+/) or URL-safe (-_) alphabet consistently.
- Tip 4: Pair this tool with the hash generator when you need checksums, or the text diff checker to compare payloads before and after encoding.