Base64 Encoder / Decoder

Encode text to Base64 or decode Base64 back to text instantly.

Runs locallyNo sign-upKeyboard first
InputText (UTF-8)
OutputBase64
SGVsbG8sIGRldnByaXghIMOcbsOvY8O4ZMOpIGFuZCBlbW9qaSDwn5GLIGFyZSBVVEYtOCBzYWZlLg==
Encoded58 B → 80 B80 charsStandard alphabetProcessed locally

What is Base64 Encoding?

Base64 is a binary-to-text encoding scheme that represents binary data using 64 ASCII characters (A-Z, a-z, 0-9, +, /). It's used to transmit binary data over text-based protocols like email (MIME), embed images in HTML/CSS (data URIs), and encode credentials in HTTP Basic Authentication. Base64 increases data size by approximately 33%.

Common use cases

  • Encoding images for inline use in HTML/CSS data URIs
  • Decoding Base64 strings from API responses
  • Encoding binary data for JSON payloads
  • Working with HTTP Basic Authentication credentials
  • Embedding fonts or small files in stylesheets

How to use

  1. 1Choose Encode or Decode; pasted Base64 opens in Decode automatically.
  2. 2Type, paste or drop a text file on the left; the output updates as you type and is UTF-8 safe (tick URL-safe for - and _).
  3. 3Press ⌘↵ to convert and copy, or Swap to move the output back into the input.

Frequently asked questions

Is Base64 encryption?

No. Base64 is an encoding, not encryption. Anyone can decode Base64 without a key. It's designed for data transport, not security. Never use Base64 to protect sensitive information.

Why does Base64 increase data size?

Base64 represents every 3 bytes of input as 4 ASCII characters, resulting in a ~33% size increase. This overhead is the trade-off for being able to transmit binary data as plain text.

What is Base64URL?

Base64URL replaces + with - and / with _ to make the output safe for URLs and filenames. JWTs use Base64URL encoding. Standard Base64 characters + and / have special meanings in URLs.