Base64 Encoder / Decoder
Convert between UTF-8 text and standard Base64. Base64 is encoding, not encryption.
What this tool does
Base64 turns arbitrary bytes — including UTF-8 Chinese text — into printable ASCII, and decodes it back. Every 3 bytes become four 6-bit groups, each mapped to one of 64 characters, with = padding when the input length is not a multiple of three. Everything runs in your browser, so pasting tokens or keys does not send them anywhere.
Typical use cases
Front-end developers inline small images as Data URLs to save a request; email (MIME) uses Base64 to carry attachments over a text-only channel; HTTP Basic auth encodes “user:password” into the Authorization header; and Base64 is the standard fallback for embedding binary data inside JSON or XML.
The reverse direction is just as common when debugging: a string starting with eyJ is usually a JWT, and an opaque config value often reveals itself after a quick decode.
Caveats
Base64 is encoding, not encryption — anyone can decode it instantly, so never use it to “protect” secrets. Encoded output is about 33% larger than the input, which makes it a poor choice for large files. Standard Base64 also uses + and /, which clash with URL syntax; use the Base64URL variant (- and _, no padding) in URLs. This tool handles UTF-8 correctly, so Chinese text round-trips without mojibake.