Base64 Encoder & Decoder
Convert text to Base64 and back again — correctly, including accents, emoji and non-Latin scripts — without sending your credentials anywhere.
Tip: Ctrl + Enter encodes, Ctrl + Shift + Enter decodes. Everything runs in your browser.
What this tool does
It converts text to Base64 and back. The conversion happens in your browser using the same primitives the
language runtime provides, so there is no round trip to a server and no copy of your string sitting in
somebody's logs — which matters when the string you are encoding is an API credential bound for an
Authorization header. Because it re-encodes through UTF-8 rather than
passing raw bytes, accented characters, emoji and non-Latin scripts survive the round trip instead of throwing
or silently corrupting.
The important caveat is what this tool is not for. Base64 is an encoding, not encryption: it makes data safe to transport through text-only channels, and it hides nothing. A Base64 string pasted into a public issue tracker is still a leaked credential. Use it for transport and storage formats that require it, and keep real secrets in a secrets manager.
How to use it
- Paste the text you want to convert into the box. It works in both directions, so the same field holds your input and the result.
- Click Encode to Base64 to convert plain text, or Decode from Base64 to go back.
- Check the banner above the box — it confirms the conversion succeeded or tells you the string was not valid Base64.
- Click Copy Result to put the output on your clipboard.
- For Basic authentication, remember the format is
username:passwordencoded as a single string, not the two parts separately.
Common use cases
-
HTTP Basic auth headers
Build the value for an
Authorization: Basicheader when testing an API. -
Data URIs for small assets
Inline a tiny icon or font directly into CSS or HTML to save a request.
-
Debugging API payloads
Decode a Base64 blob from a webhook or log line to see what was actually sent.
-
Inspecting JWT segments
Read the header and payload of a token to check its claims and expiry.
Frequently asked questions
Is Base64 a form of encryption?
No, and treating it as one is a common and costly mistake. Base64 is a reversible encoding that turns arbitrary bytes into 64 printable characters so they can travel through systems that only handle text. Anyone can decode it in one step. Secrets still need real encryption such as TLS in transit and a proper secrets manager at rest.
Why do my accented characters or emoji break other converters?
Plain btoa and atob only accept
Latin-1 bytes. Feeding them a character outside that range throws an error or silently corrupts the text.
This tool percent-encodes the string to UTF-8 bytes first, so accents, emoji and non-Latin scripts survive
the round trip intact.
What is Base64 actually used for?
The most common uses are HTTP Basic authentication headers, embedding small images directly in CSS or HTML as data URIs, transporting binary attachments inside JSON or XML APIs, and encoding JWT segments. In each case the goal is to move binary data through a text-only channel.