ToolHarbor

Base64 Encoder/Decoder

Encode text to Base64 or decode Base64 strings instantly. Free online converter with UTF-8 support.

Features

  • Encode any text to Base64 format
  • Decode Base64 back to plain text
  • Full UTF-8 and Unicode support
  • Works offline - no server requests
  • Swap between input and output instantly
  • Copy results with one click

How to Use

  1. 1Select "Encode" or "Decode" mode using the toggle buttons
  2. 2Paste or type your text in the input field
  3. 3Click the action button to convert
  4. 4Copy the result using the Copy button
  5. 5Use Swap to quickly reverse the operation

Examples

Encoding plain text

Input

Hello, World!

Output

SGVsbG8sIFdvcmxkIQ==
Encoding with special characters

Input

User: admin@example.com

Output

VXNlcjogYWRtaW5AZXhhbXBsZS5jb20=
Decoding Base64

Input

VG9vbEhhcmJvciByb2NrcyE=

Output

ToolHarbor rocks!

What is Base64 Encoding?

Base64 is a binary-to-text encoding scheme that represents binary data using a set of 64 ASCII characters. It was designed to safely transmit binary data over systems that only support text, such as email attachments, data URLs, and API payloads. The Base64 encoder converts any input into a safe string that can travel through text-only channels without corruption.

The Base64 alphabet consists of uppercase letters (A-Z), lowercase letters (a-z), digits (0-9), and two additional characters (+ and /). The = character is used for padding when the input length is not divisible by 3. This encoding increases the data size by approximately 33%, but ensures safe transmission across all text-based protocols. URL-safe variants replace + and / with - and _ for use in URLs.

Common use cases for Base64 encoding include embedding images directly in HTML or CSS (data URIs), encoding authentication credentials in HTTP headers (Basic Auth), storing binary data in JSON or XML documents, and transmitting files through APIs that only accept text. Many JWT tokens also use Base64 encoding for their payload sections.

Our Base64 encoder and decoder handles UTF-8 text properly, meaning you can encode and decode text containing special characters, emojis, and characters from any language. Whether you need to encode a simple string or decode a complex payload, this tool processes it instantly.

The encoding and decoding happens entirely in your browser using client-side JavaScript. Your data is never sent to any server, making this Base64 converter safe for sensitive information like passwords, API keys, or personal data. No registration required — just paste, convert, and copy.

Frequently Asked Questions

Related Tools