Base64-encode Text

Paste text and get Base64 instantly, standard or URL-safe.

Options

The result updates as you type. Ctrl + Enter encodes now.

Base64 output

How to encode text to Base64

Paste your text into Your text, or press Load example to try Hello, world! Café 😀. The Base64 output appears next to it and updates as you type. Tick URL-safe alphabet for URLs and filenames, then copy the result or download it as a .txt file. Everything runs in your browser, so nothing you paste is uploaded.

Examples

InputOutput
hello aGVsbG8=
✓ 4pyT
😀 8J+YgA==

Limits and edge cases

  • Input is encoded as UTF-8 bytes first, so any Unicode works: café is 5 bytes and encodes to Y2Fmw6k=.
  • Standard and URL-safe alphabets differ only in three characters:
Variant62nd / 63rd charPadding
Standard+ /= kept (e.g. f → Zg==)
URL-safe- _removed (e.g. f → Zg)
  • Standard output is padded with = to a multiple of 4 characters; URL-safe mode strips that padding.
  • Line breaks are encoded as bytes, not wrapped: a newline (LF) encodes inside the output, and the result is always one continuous string.

Frequently asked questions

How do I encode text to Base64?

Paste your text into the input box and the Base64 output appears instantly. Copy it or download it as a .txt file.

Does it support Unicode and emoji?

Yes. Input is encoded as UTF-8 bytes first, so accented letters, symbols and emoji all encode correctly.

What is the URL-safe alphabet?

URL-safe Base64 replaces + with -, / with _, and removes trailing = padding, so the output can go in URLs and filenames without escaping.

Why does the output end with = signs?

Standard Base64 pads the output with = to a multiple of 4 characters. URL-safe mode removes this padding.

Are line breaks wrapped or encoded?

Line breaks are encoded as bytes (LF is Cg==), not wrapped. The output is one continuous Base64 string.

Is my text uploaded anywhere?

No. Encoding runs in your browser with JavaScript and nothing is sent to a server. Inputs under 200 KB are kept in your browser's local storage so they are still there when you come back.