Skip to main content

Base64 Encoder / Decoder

Convert text to and from Base64, the encoding used to carry binary data through systems that only handle text.

Runs entirely in your browser, which matters because the Base64 strings developers decode are very often JWTs, basic-auth headers, and API credentials.

This tool runs entirely in your browser

This tool runs entirely in your browser. The data you paste is processed on your device and never sent to Filorra.

That is not a small detail for developer tools. API responses, tokens, config files, and log excerpts routinely contain credentials and customer data, and pasting them into a server-side tool means disclosing them to a third party.

How to use Base64 Encoder / Decoder

  1. Paste your text or Base64 string

    Either direction works.

  2. Encode or decode

    Conversion happens instantly using your browser's built-in functions.

  3. Copy the output

    The result is generated locally and never transmitted.

Base64 is not encryption, and treating it as such is a security bug

This is the single most important thing to understand about Base64, and it is misunderstood often enough to cause real incidents.

Base64 is an encoding: a reversible, keyless transformation into a restricted character set. Anyone can decode it instantly, with no secret of any kind. It provides zero confidentiality.

So a password stored Base64-encoded in a config file is stored in plain text with an extra step. A basic-auth header is your credentials in the clear. The `Authorization: Basic` scheme is exactly this, which is why it is only acceptable over HTTPS — the transport provides the security, the encoding provides none.

If the requirement is to keep something secret, you need encryption with a key, or hashing for verification. Base64 exists to make binary data survive text-only channels, and nothing more.

Decoding a JWT

JSON Web Tokens are the most common thing people decode, and their structure is simple once seen.

A JWT is three Base64url-encoded segments separated by dots: header, payload, and signature. Decoding the first two reveals the algorithm and the claims — user ID, expiry, issuer, scopes — as readable JSON. This is entirely by design: a JWT payload is signed, not encrypted, and anyone holding the token can read it.

Two practical consequences. Never put anything confidential in a JWT payload, because every party the token passes through can read it. And decoding a token does not verify it — the signature check requires the key, and reading the claims proves nothing about authenticity.

Note that JWTs use Base64url, a variant that replaces `+` and `/` with `-` and `_` and usually drops the padding, so segments sometimes need adjusting before a strict decoder accepts them.

Size, and why you should not Base64 large files

Base64 represents three bytes using four characters, so encoded data is about 33% larger than the original, plus line breaks in some variants.

This is why embedding large images as data URIs in CSS or HTML is usually a mistake: you inflate the payload by a third, you make it uncacheable independently of the document, and you block rendering on the whole inline blob. It is reasonable for tiny assets like a 200-byte icon, and a poor trade for anything larger.

When to use Base64 Encoder / Decoder

  • Inspecting the claims inside a JWT while debugging authentication.
  • Decoding a basic-auth header to check which credentials are being sent.
  • Encoding a small asset as a data URI.
  • Decoding Base64 fields inside an API response or config file.

Common problems

Decoding fails on a JWT segment.
JWTs use Base64url, which substitutes - and _ for + and / and often omits padding. Convert the characters back and pad the length to a multiple of four.
Non-English characters come back garbled.
Some decoders only handle Latin-1 text. Unicode text must be converted to UTF-8 bytes first, which this tool does for you.
The encoded output is bigger than the input.
Expected — Base64 adds roughly 33%. It exists to make binary safe for text channels, not to compress.
Is Base64 safe for storing passwords?
No. It is trivially reversible by anyone. Use encryption for secrets, or a password hashing function such as bcrypt or Argon2 for credentials.

Frequently asked questions

Is my data sent to a server?
No. Encoding and decoding use your browser's built-in functions. This makes it safe for JWTs and credentials.
Is Base64 a form of encryption?
No. It is a reversible encoding with no key. Anyone can decode it instantly, so it provides no confidentiality at all.
Why does my JWT not decode cleanly?
JWTs use the Base64url variant, which replaces + and / with - and _ and usually drops padding.
Why is the encoded string longer than the original?
Base64 uses four characters for every three bytes, an increase of about 33%. It is an encoding, not a compression.

Learn more

Guides and answers that explain how this tool's job actually works.