Text Tools
Encode and decode text
Base64, URL encoding and HTML entities, in both directions, with correct UTF-8 handling.
- Free, no signup
- No upload — runs on your device
- No watermark
- Unlimited use
Base64 Encoder
Processed locallybtoa() throws on any character above 255, which is most of the world
The browser's built-in btoa() function accepts only Latin-1 — code points 0 to 255. Feed it an emoji, a Chinese character, or the word "naïve", and it throws an InvalidCharacterError. Countless encoders on the web wrap btoa() directly and simply fail on non-English input, or worse, silently mangle it.
The correct approach is to encode the string to UTF-8 bytes first, then Base64 those bytes. That is what happens here: TextEncoder produces the byte sequence, and each byte is safely below 256 by construction. Decoding reverses it with TextDecoder. An emoji survives the round trip; so does Arabic, so does an em dash.
Worth knowing: Base64 is not encryption. It is a way to represent binary data in text-safe characters, and anyone can decode it instantly. If you are Base64-encoding a password to hide it, you have hidden nothing.
How it works
- Choose a mode — encode or decode
- Paste your text
- Copy the output