Skip to content

Base64 Encoder / Decoder

Encode text to Base64 or decode Base64 back to readable text instantly. Full UTF-8 support, real-time conversion, one-click copy.

Converter

Text → Base64

Base64 → Text

What Is Base64?

Base64 is a binary-to-text encoding scheme that represents binary data using 64 ASCII characters: A–Z, a–z, 0–9, +, and /, with = for padding. It's defined in RFC 4648.

Every 3 bytes of input become 4 Base64 characters, so encoded output is roughly 33% larger than the original.

Common uses include:

  • Email attachments (MIME encoding)
  • Data URIs — embedding images and fonts directly in HTML/CSS
  • API payloads — transmitting binary data in JSON
  • Authentication — HTTP Basic Auth headers (Authorization: Basic <base64>)

Base64 vs Base64URL

Standard Base64 uses + and /, which are unsafe in URLs. Base64URL (defined in RFC 7515) replaces them with - and _, and drops the = padding. It's used in JWT tokens and other web-friendly contexts.

Base64Base64URL
Character 62+-
Character 63/_
Padding=None
Used inEmail MIME, Data URIsJWT, URL parameters

Common Use Cases

  • Embed images in HTML — Convert small images to Base64 data URIs to avoid extra HTTP requests
  • API development — Encode credentials for HTTP Basic Auth, or transmit binary payloads in JSON
  • Debug encoded data — Quickly decode Base64 strings found in logs, tokens, or network requests
  • Configuration files — Many systems (Kubernetes, Docker) accept Base64-encoded values in configs

FAQ

Does Base64 encrypt my data? No. Base64 is an encoding scheme, not encryption. Anyone can decode it. Never use Base64 as a security measure — it provides zero confidentiality.

Why does the output look longer than the input? Base64 expands data by about 33% because it represents every 3 bytes as 4 characters. This is normal and expected.

Does this tool handle non-English text? Yes. This tool fully supports UTF-8, so you can encode and decode Chinese, Japanese, Korean, emoji, and any other Unicode text correctly.

What happens if I paste invalid Base64 into the decoder? The decoder validates the input and shows a clear error message if it's not valid Base64.