Homeโ€บ Unit Conversionsโ€บ Base64 Encode / Decode

Base64 Encode / Decode

Encode text to Base64 or decode Base64 back to text. Useful for emails, embedded data, and inspecting tokens. Uses native browser btoa/atob.

Inputs

Output
โ€”
Input length
โ€”
Output length
โ€”
Size ratio
โ€”

About Base64 Encode / Decode

What is Base64?

A text encoding that uses 64 ASCII characters (A-Z, a-z, 0-9, +, /, with = padding) to represent arbitrary binary data. Designed in the 1980s for email attachments โ€” keeps binary safe through text-only channels.

Size cost

Base64 increases data size by ~33% (every 3 bytes becomes 4 ASCII characters). Why your email attachments are bigger than the source files; why embedded data URIs grow images.

Not encryption

Base64 is encoding, not encryption โ€” anyone can decode it instantly. Donโ€™t use it to "hide" passwords or secrets. Itโ€™s just a binary-to-text wrapper.