PTBox

Online Base64 Encoder & Decoder

Online Base64 encoder/decoder supporting any Unicode text and a URL-safe variant. Runs entirely in the browser — input is never uploaded.

Usage

Base64 encodes binary data as printable ASCII — commonly used in URLs, email attachments, Data URLs and cookies.

Uses the browser's btoa / atob with extra UTF-8 handling so non-ASCII text (CJK, emoji) round-trips correctly. The "URL safe" option replaces +// with -/_ and strips trailing =.

Use cases

Embedding Data URLs

Convert small icons to Data URLs and inline them in HTML / CSS to save an HTTP request.

Inspecting JWTs / tokens

JWT header and payload are Base64-URL encoded — decode to see what's inside.

Email attachments

SMTP only handles 7-bit ASCII, so binary attachments are wrapped in Base64.

Keys in config files

Certificates and binary keys in YAML / JSON files are usually stored as Base64 strings.

FAQ

Why does Base64 make the data larger?

Base64 expands every 3 bytes to 4 characters — about 33% overhead.

What is URL-safe mode?

Replaces + with -, / with _ and strips trailing =. The result can be embedded in URLs without further percent-encoding.

Does it handle CJK and emoji?

Yes. The tool first encodes the string as UTF-8, then Base64s the bytes — any Unicode round-trips correctly.

Is Base64 encryption?

No. It's encoding, not encryption — anyone can decode it. Never use it to protect sensitive data.

Related tools

Comments

0 / 1000