Base64 Encoder / Decoder
Encode text to Base64 or decode Base64 strings online for free — supports full UTF-8 including emoji and Unicode. No sign-up, no account, nothing leaves your browser.
How It Works
Choose Encode or Decode
Select what you want to do — convert plain text to Base64, or turn a Base64 string back into readable text. Your data stays entirely in your browser.
Paste your input
Type or paste into the input box. The result appears instantly — no button to press, no waiting around.
Copy or swap
Click Copy to grab the output. Use the Swap button to reverse the operation and verify your data encodes and decodes correctly.
How to Encode or Decode Base64 Online
- Select Encode or Decode using the toggle at the top of the tool.
- Paste or type your text into the input box. The output updates instantly as you type.
- Click Copy to send the result to your clipboard. Click Swap to reverse the direction and verify a round-trip.
Features
- Instant results: Output updates as you type — no button to press.
- Full UTF-8 support: Handles emoji, accented characters, Chinese, Arabic, and all other Unicode text correctly.
- One-click Swap: Reverses the operation and swaps input/output so you can verify round-trips in seconds.
- Character and size stats: Shows input and output lengths and, when encoding, the Base64 overhead ratio.
- Your data stays private: Everything runs in your browser using
btoa(),atob(),TextEncoder, andTextDecoder— nothing is uploaded, stored, or logged. - No account required: Open the page and start encoding or decoding straight away.
- Works offline: Pure JavaScript — once the page has loaded, no network connection is needed.
What is Base64?
Base64 is a binary-to-text encoding scheme that represents binary data using 64 printable ASCII characters
(A–Z, a–z, 0–9, +, and /). It is widely used to embed binary content — such as
images, certificates, or file attachments — inside text-based formats like JSON, XML, HTML, and email headers.
Because Base64 uses roughly 33% more characters than the original data, it trades compactness for
compatibility.
Frequently Asked Questions
Is my data uploaded to your servers?
No. The encoder and decoder run entirely in your browser using the built-in btoa() and atob() functions combined with the TextEncoder/TextDecoder APIs. Your text never leaves your device.
What is Base64 encoding used for?
Base64 is used to safely transmit binary data over channels that only support text — for example, embedding images directly in HTML or CSS, sending file attachments in email (MIME), storing binary data in JSON, and encoding authentication credentials in HTTP headers.
Does this tool support UTF-8 and Unicode characters?
Yes. The encoder uses the browser's TextEncoder API to convert your string to UTF-8 bytes before encoding, so emoji, accented characters, and all Unicode text work correctly.
What does the Swap button do?
Swap takes the current output and places it into the input field, then automatically switches between Encode and Decode mode. This lets you verify a round-trip — encode some text, click Swap, and you'll see the original text back.
Is this Base64 encoder free to use?
Yes, completely free — no account, no sign-up, and no usage limits.
Does the tool work offline?
Yes. The tool is pure client-side JavaScript — once the page has loaded, it works without an internet connection.