Base64 Encode & Decode Online — Unicode & URL-safe

Convert text between UTF-8 and Base64 without leaving your browser. Turn on the URL-safe alphabet when you embed tokens in URLs or JWT segments. Copy the result when you are done. Nothing is uploaded.

Loading…
Base64 encoder and decoder
FastMinify converts arbitrary Unicode text to Base64 and back using UTF-8 bytes, which is how modern stacks safely embed international characters. Use standard Base64 for storage or checksum payloads. Enable URL-safe mode when you embed blobs inside paths, cookies, or JWT-like segments without extra escaping.

How this Base64 tool works

Choose Encode to turn readable text into a compact ASCII-safe form that uses only letters, digits, +, / and optional padding. Choose Decode to reverse it: paste Base64, with or without URL-safe characters, and the original Unicode string appears in the output. Everything runs locally in your browser. That helps when you prepare snippets for APIs, compare payloads with backend logs, or check a configuration secret.

URL-safe Base64 option

RFC 4648 defines an alternate alphabet where + becomes - and / becomes _. Padding characters (=) are typically trimmed so values fit cleanly inside URLs or HTTP headers. Remember that Base64 is encoding, not encryption: anyone can decode it. Treat it as a transport representation, not a security boundary.

Practical examples

Unicode caption → Base64

Sample input

FastMinify ships developer tools for minify, beautify, and convert workflows — all processing stays in your browser. Accents: café, naïve, Zürich, São Paulo. Emoji: 🚀✨📦

Expected output

RmFzdE1pbmlmeSBzaGlwcyBkZXZlbG9wZXIgdG9vbHMgZm9yIG1pbmlmeSwgYmVhdXRpZnksIGFuZCBjb252ZXJ0IHdvcmtmbG93cyDigJQgYWxsIHByb2Nlc3Npbmcgc3RheXMgaW4geW91ciBicm93c2VyLiBBY2NlbnRzOiBjYWbDqSwgbmHDr3ZlLCBaw7xyaWNoLCBTw6NvIFBhdWxvLiBFbW9qaTog8J+agOKcqPCfk6Y=

JWT-style fragment (URL-safe)

Sample input

{"alg":"HS256","typ":"JWT"}

Expected output

eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9

Combine with other FastMinify utilities

Need percent-encoding instead of radix-64? Open the URL encoder. Cleaning up markup snippets goes well with the HTML entities tool, and compact scripts come from our JavaScript minifier.

Base64 FAQ

Answers teams ask before piping strings through Base64 pipelines

Does Base64 change my Unicode characters?

No meaningful loss occurs: UTF-8 preserves emoji and accented glyphs before the Base64 stage. Decoding reconstructs the exact original text.

When should I enable URL-safe mode?

Turn it on whenever + or / would collide with URL delimiters or when your downstream parser expects JWT/Base64URL semantics.

Why does decoding fail with InvalidCharacterError?

Common culprits include stray whitespace, missing padding (standard mode only), or mixing URL-safe characters without enabling the toggle.

Is data uploaded?

No. Conversions stay inside your browser tab.

How does this relate to Data URIs?

You can Base64-encode binaries or SVG/text payloads for data: URIs, but validate CSP rules before deploying inline assets.

Can I embed secrets?

Base64 does not protect confidentiality. Use proper secret managers instead of assuming encoded strings are hidden.

Is Base64 the same as encryption?

No. Base64 only represents bytes as ASCII text; anyone can decode it. It is not a substitute for encryption or signing.

Does padding matter when decoding?

In standard mode, a missing = padding can cause decode errors. URL-safe mode often omits the padding, so turn on the matching option to keep input and settings aligned.

Encode or decode Base64, URLs, HTML entities and JWTs, and generate hashes and HMACs in your browser.