Base64 Encoder / Decoder

Encode and decode Base64 strings. Free online Base64 encoder and decoder supporting text and file conversion.

About Base64 Encoding

Base64 is a binary-to-text encoding scheme that represents binary data in an ASCII string format. It's commonly used to encode binary data for transmission over media designed to handle text.

Features

  • Encode text to Base64 format
  • Decode Base64 strings back to text
  • Support for UTF-8 encoding
  • Handle special characters and unicode
  • Copy results with one click

Common Use Cases

  • Email Attachments: MIME email attachments are encoded in Base64
  • Data URIs: Embedding images in CSS or HTML
  • Authentication: HTTP Basic Authentication uses Base64
  • APIs: Some APIs require Base64-encoded data
  • Storage: Storing binary data in text-only systems

How It Works

Base64 encoding converts binary data into a set of 64 ASCII characters (A-Z, a-z, 0-9, +, /). Every 3 bytes of binary data are represented by 4 Base64 characters. If the input length isn't divisible by 3, padding characters (=) are added.

Example

Original: Hello, World!

Base64: SGVsbG8sIFdvcmxkIQ==