Base64 Encoder & Decoder
Encode or decode base64 strings instantly. UTF-8 safe, runs locally in your browser — no upload, no signup.
- Runs in browser
- No signup
- No tracking
How to use Base64 Encoder & Decoder
Pick Encode or Decode.
Paste your input on the left.
Result updates live on the right.
Click Copy to grab the output.
When to use it
Embedding small images as data URIs.
Decoding the payload of a JWT.
Encoding credentials for HTTP Basic Auth.
Inspecting base64-encoded API responses.
What it fixes
Mojibake when btoa() chokes on UTF-8.
Padding errors from truncated base64.
Slow CLI round-trips for one-off encoding.
About Base64 Encoder & Decoder
Base64 is the standard binary-to-text encoding for embedding data in URLs, JSON, JWTs, data URIs, and email attachments. This tool handles both directions in your browser using native APIs.
UTF-8 support means emoji and non-ASCII text round-trip correctly — a common gotcha with raw btoa() that this tool wraps.
References: RFC 4648 — Base64 spec · MDN — btoa / atob
Frequently asked
Does it support UTF-8 / emoji?
Yes. The tool round-trips emoji, accented characters, and any UTF-8 input correctly.
Is my data sent to a server?
No. Encoding and decoding run with the native btoa/atob browser APIs. Your input never leaves the page.
What about base64url (URL-safe variant)?
Standard base64 only. Replace + with - and / with _, and strip padding to get base64url manually.
Discussion
Related tools
All toolsURL Encoder & Decoder
Percent-encode URL components or decode them back. Built on encodeURIComponent.
Encode / DecodeHash Generator
MD5, SHA-1, SHA-256, SHA-384, SHA-512 hashes of text or files. WebCrypto, runs locally.
Encode / DecodeImage to Base64
Convert any image to a base64 data URI. Copy as data URI, raw base64, CSS, or HTML snippet.
Encode / Decode