Developer Tools

Base64 Encoder & Decoder

Encode text to Base64 or decode Base64 back to UTF-8. URL-safe variant supported. Browser-only — your data stays private.

Input (plain text)
Output (Base64)

Base64 in 30 seconds

Base64 turns any binary or text data into a 64-character ASCII alphabet. Ideal for transporting data through systems that only handle text safely (URLs, JSON, email). Choose "URL-safe" if your output goes into a URL — it swaps + and / for - and _ and drops padding.

Frequently Asked Questions

What is Base64?
Base64 is an encoding scheme that converts binary or text data to a 64-character ASCII string (A-Z, a-z, 0-9, +, /). It's widely used in email (MIME), JWTs, data URIs, and embedding small images in CSS or HTML.
Is Base64 encryption?
No. Base64 is encoding, not encryption. Anyone can decode it back to the original. Never use Base64 to "hide" passwords or secrets — it's reversible without a key.
What is URL-safe Base64?
Standard Base64 uses + and / characters which need URL-encoding when used in query strings or paths. URL-safe Base64 substitutes - for + and _ for /, plus removes padding (=), so it works directly in URLs and JWTs.
Why does my Base64 string have = at the end?
Padding. Base64 encodes 3 bytes at a time into 4 characters. If the input length isn't divisible by 3, the output is padded with = (one or two) to make the length a multiple of 4. URL-safe variants typically drop the padding.
How big is Base64 vs the original?
Base64-encoded data is ~33% larger than the source bytes (4 output chars per 3 input bytes). For a 100KB image, expect a ~133KB Base64 string. That's why data URIs only make sense for tiny resources (icons, fonts).

Related Calculators