Encode and decode Base64 online, instantly and privately
This free Base64 encoder and decoder converts text to Base64 and back with a single click. Paste any text to turn it into a compact, text-safe Base64 string, or paste a Base64 value to recover the original text. Everything happens in your browser, so even sensitive strings never leave your computer — there is nothing to install and no account to create. The tool is fully UTF-8 aware, which means accented letters, emoji and non-Latin scripts round-trip perfectly rather than being corrupted.
How to encode or decode Base64
- Paste your input Type or paste your plain text (to encode) or a Base64 string (to decode) into the input box.
- Choose a direction Click “Encode to Base64” to convert text into Base64, or “Decode from Base64” to turn Base64 back into text.
- Read the result The converted value appears instantly in the result box below. If the Base64 is invalid, a clear message tells you.
- Copy it Press Copy result to copy the output to your clipboard, then paste it wherever you need it.
What is Base64 and when do you use it?
Base64 is a way of representing binary data — or any text — using only 64 printable ASCII characters. It exists because many systems were designed to carry text, not raw bytes, and will mangle or reject characters they do not expect. By re-expressing data in a safe, limited alphabet, Base64 lets you move binary content through text-only channels untouched.
You will most often meet Base64 in these situations:
- Data URIs. Small images, icons and fonts can be embedded directly in CSS or
HTML as
data:image/png;base64,…, saving an extra network request. - JSON and web APIs. Binary payloads such as file contents or signatures are Base64-encoded so they can travel inside a JSON string field.
- Email attachments. The MIME standard encodes attachments in Base64 so they survive mail servers that only handle plain text.
- Tokens and headers. Values such as JWT segments and HTTP Basic Auth credentials are Base64 (or URL-safe Base64) encoded for safe transport.
Base64 is encoding, not encryption
This is the single most important thing to understand about Base64: it offers no security at all. Encoding simply rearranges data into a different representation, and anyone can reverse it instantly — including this very tool. Seeing an unreadable jumble of letters can create a false sense of safety, but a Base64 string is effectively plain text. Never use Base64 to protect passwords, API keys, personal data or any other secret. If you need genuine confidentiality, use real encryption such as AES, and keep the keys safe. Base64 is for transport, not for hiding things.
Standard versus URL-safe Base64
Standard Base64 includes the characters + and /, which have special
meanings inside URLs. To avoid escaping, a URL-safe variant replaces them with -
and _ and often drops the = padding. This decoder accepts both: it
automatically normalises URL-safe input and restores any missing padding, so you can paste a
value straight from a URL, a JWT or a config file without cleaning it up first.