DevSandbox
0 network calls
0 characters
Local

Base64 & Base64URL encoder and decoder

Convert text, binaries, and tokens between plain UTF-8 and Base64, URL-safe Base64URL, or hexadecimal format. Executes 100% locally with zero external network transmission.

How to encode or decode Base64

  1. Choose Encode to transform plain text into Base64, or Decode to convert Base64 back to readable text.
  2. Select your target format:
    • Standard Base64 — standard RFC 4648 with +, /, and padding =.
    • URL-safe Base64URL — replaces + with - and / with _ (used in JWTs and URLs).
    • Hexadecimal — raw binary byte representation in base 16.
  3. Type or paste your text. The output is generated in real-time as you type.
  4. Use Copy Output or Download to export your result.

Why UTF-8 support matters for Base64

Standard JavaScript btoa() throws an exception on characters outside the Latin-1 range (such as emojis or non-ASCII characters). DevSandbox utilizes modern TextEncoder and TextDecoder streams to ensure full multi-byte Unicode safety without crashing.

Frequently asked questions

What is the difference between Base64 and Base64URL?

Standard Base64 uses + and / characters with = padding. Base64URL replaces + with - and / with _, omitting padding so that the encoded string is safe for use in URL query parameters, path segments, and JSON Web Tokens.

Does this encoder support UTF-8 characters and emojis?

Yes. DevSandbox uses modern TextEncoder and TextDecoder streams rather than legacy Latin-1 restricted functions, ensuring full multi-byte Unicode and emoji compatibility.

Can I encode binary files?

Yes. You can paste or drag-and-drop text and data files directly into the editor to encode them into Base64 or Hex.