Base64 Encoder / Decoder

Character Count: 0 | Word Count: 0 | Sentence Count: 0 | Line Count: 0

Base64 encode and decode: convert text and binary-safe strings

Base64 encoding represents binary data as ASCII text using 64 URL-safe characters. Developers use it for embedding small images in data URLs, passing binary blobs through JSON, or decoding tokens and headers during debugging—not for encryption or compression.

This tool encodes and decodes UTF-8 text in the browser. It is ideal for quick experiments, not for secrets management or large files.

How to use this converter

  1. Paste text to encode, or a Base64 string to decode.
  2. Switch between Encode and Decode modes.
  3. Copy the result; verify padding (`=`) when decoding legacy payloads.

Before and after examples

OriginalConvertedNotes
HelloSGVsbG8=Simple ASCII encode
SGVsbG8=HelloDecode

Base64 is encoding, not encryption

Anyone can decode Base64. Do not treat encoded passwords or API keys as protected. Use proper encryption and secret stores in production. Base64 only changes representation so binary-safe transports (email, JSON strings) can carry bytes.

UTF-8 text, padding, and URL-safe variants

Text is encoded as UTF-8 bytes before Base64. Decoding assumes standard Base64 alphabet; URL-safe variants (`-` and `_`) may need normalization in strict decoders. Padding characters at the end are required for some libraries—include them when decoding fails.

Common debugging uses

Inspect JWT payload segments (middle part only—verify signatures in proper tools). Decode a Basic auth header during API troubleshooting. Encode a small SVG for a data URL prototype. For images, dedicated image-to-Base64 workflows may be more convenient.

Frequently asked questions

Is Base64 the same as encryption?

No. It is reversible encoding with no secret key.

Can I encode files?

This page targets text pasted into the box. Very large inputs may be truncated for responsiveness.

Why does decoding fail?

Check for missing padding, line breaks in the paste, or URL-safe alphabet differences.

Guides and deeper reading