Base64 Encoder/Decoder

Our Base64 encoder decoder converts text to Base64 encoding and back in real-time. Paste any text and get the Base64-encoded version, or paste Base64 to decode it back to readable text. Supports standard Base64 (RFC 4648) and URL-safe Base64. Handles UTF-8 characters, JSON strings, and large text. All processing is client-side — your data never leaves your browser.

star 4.9
auto_awesome AI
New
0 characters
0 characters

auto_awesome AI Analysis

Powered by Claude

Base64 Analysis:

  • Mode: Encode text → Base64
  • Output size: ~33% larger than input

Tip: Base64 is encoding, not encryption. Never use it for security.

lightbulb Tips

  • Base64 output is always ~33% larger than input
  • URL-safe Base64 uses - and _ instead of + and /
  • Base64 is encoding, NOT encryption
  • 3 input bytes = 4 Base64 characters

How to Use This Calculator

swap_horiz

Choose Mode

Select Encode to convert text to Base64, or Decode to convert Base64 back to text.

text_fields

Enter Input

Type or paste your text (for encoding) or Base64 string (for decoding).

content_copy

Get Result

The result appears instantly. Click Copy to copy to clipboard.

link

URL-Safe Option

Toggle URL-safe mode to use - and _ instead of + and / for URL-compatible output.

The Formula

Base64 encoding converts binary data to printable ASCII text by splitting input bytes into 6-bit groups and mapping each group to one of 64 characters (A-Z, a-z, 0-9, +, /). Since 3 bytes (24 bits) map to 4 Base64 characters, the output is ~33% larger than the input. Padding (=) is added if the input length isn't a multiple of 3.

Base64 = encode(input bytes) → 6-bit groups → A-Za-z0-9+/ alphabet

lightbulb Variables Explained

  • input bytes UTF-8 encoded bytes of the input text
  • 6-bit groups Input split into 6-bit chunks (vs 8-bit bytes)
  • A-Za-z0-9+/ 64 printable ASCII characters used in the encoding alphabet
  • = (padding) Padding character added to make output length a multiple of 4

tips_and_updates Pro Tips

1

Base64 output is always ~33% larger than the input

2

URL-safe Base64 replaces + with - and / with _ (useful for URLs and filenames)

3

Base64 is encoding, NOT encryption — anyone can decode it, so never use it for security

4

Use Base64 to embed small images in HTML/CSS via data URIs

5

JSON Web Tokens (JWT) use URL-safe Base64 encoding for header and payload

6

The = padding at the end can be safely removed for URL-safe Base64

7

Base64 handles binary data — it's how email attachments are transmitted

Encode & Decode Base64 Online

Our free Base64 encoder decoder converts text to Base64 and back instantly. Supports standard and URL-safe Base64, UTF-8 characters, and large text. All processing happens in your browser — your data stays private.

Base64 Encoder - Text to Base64

Convert any text to Base64 encoding instantly. Our encoder handles UTF-8 characters, JSON strings, HTML, and any text input. Copy the Base64 output for use in APIs, data URIs, email encoding, or configuration files.

Base64 Decoder - Base64 to Text

Decode any Base64 string back to readable text. Paste Base64-encoded content and see the original text instantly. Handles standard Base64, URL-safe Base64, and Base64 with or without padding characters.

Frequently Asked Questions

sell

Tags

verified

Data sourced from trusted institutions

All formulas verified against official standards.