Free

Base64 Encoder & Decoder

Both alphabets, correct for every character - including the accented and non-Latin text that breaks most in-browser encoders.

  • Free forever
  • No signup
  • Runs in your browser

At a glance

Takes
Text, a URL, or a file from your own machine
Returns
Base64 or base64url, encoded or decoded
Handles
UTF-8 properly, so accented characters and emoji survive the round trip
Privacy
Encoded in your browser - the file is never uploaded

Nothing you type leaves this page

This tool runs entirely in your browser. Nothing you type or paste is sent to Revquix or to anyone else, no account is needed, and the page keeps working with your network disconnected.

Full detail in our privacy policy and AI policy.

How this works

About Base64 Encoder

What it checks, what it deliberately does not, and how to read the output.

Why most browser-based Base64 tools mangle your text

The browser's built-in btoa does not accept text. It accepts a string of bytes, meaning every code unit must be 255 or below, so btoa applied to a word with an accent throws an error and applied to certain other input produces the wrong answer. The workaround that circulated for years relied on unescape, a function deprecated since the 1990s. Tools built on either are broken for most of the world's writing systems, and the failure is usually silent mojibake rather than an error.

This tool encodes through TextEncoder into real bytes and then applies the alphabet directly, so Hindi, Chinese, emoji, the rupee sign and accented Latin all round-trip exactly. Decoding runs the same path in reverse and reports failure rather than substituting replacement characters, which means it can tell you honestly when the input was binary rather than text.

Standard or URL-safe

Standard Base64 uses + and /, which are both meaningful inside a URL and inside a filename. RFC 4648 §5 defines the URL-safe alphabet that substitutes - and _, and that is what JWTs, WebPush keys and most token formats actually use. Padding is usually dropped in that context, which is why the padding switch exists - and why a token rejected by one library and accepted by another is very often just this.

Decoding accepts either alphabet regardless of the switch, because somebody pasting a JWT segment wants it decoded rather than corrected.

  • Swap moves the output into the input and flips direction, for a round-trip check
  • Optional 76-character line wrapping, as MIME requires
  • Byte counts, so you can see the 33% size increase encoding costs
  • Binary output shown as hex rather than as broken text

Base64 is not encryption

This is worth stating plainly because it underlies a recurring category of security incident. Base64 has no key and provides no secrecy: it is a way of carrying arbitrary bytes through a channel that only tolerates text. Anyone holding an encoded string can reverse it in one step, including this page. A credential that is merely Base64-encoded is a credential in plain text with an extra step.

What it will not do

It does not take file uploads. That keeps the promise on this page simple and literal - there is no upload path to reason about - and a file-to-Base64 conversion is better done with a one-line shell command anyway.

It also does not decode nested or multiply-encoded input automatically, and it will not guess at a string that is nearly Base64. A truncated or corrupted input is reported with the position of the problem rather than partially decoded.

FAQ

Questions people actually ask

The ones that come up before somebody uploads anything.

Why does my accented or emoji text encode incorrectly elsewhere?

Because most in-browser tools use btoa, which only accepts characters up to U+00FF and either throws or produces wrong output beyond that. This tool converts text to UTF-8 bytes first and encodes the bytes, which is correct for every character, so naïve, ₹ and emoji all round-trip exactly.

What is the difference between Base64 and base64url?

Only two characters: base64url uses - and _ where standard Base64 uses + and /, so the result is safe inside a URL, a filename or a JWT. Padding with = is usually omitted as well. If a token is being rejected by one library and accepted by another, this difference is the first thing to check.

Is Base64 a form of encryption?

No, and treating it as one is a real source of security incidents. It has no key and offers no secrecy - anyone can decode it instantly, including this page. Use it to transport bytes through a text-only channel, never to protect them.

Why is Base64 output larger than the input?

Because it represents three bytes using four characters, which is a fixed increase of about 33%, plus padding and any line breaks. That is the cost of the format, and it is why embedding large images as Base64 data URIs makes pages heavier than linking the file.

Is my input uploaded?

No. Encoding and decoding both happen in your browser, there is no network request at any point, and the page keeps working offline. That is checkable in your browser's network tab, which is the only form of this assurance worth anything.

Next, try one of these

More from Developer, or browse the full catalogue.

Encoding is not encryption

If it needed to be secret, Base64 did not do it

Base64 is a transport format, and treating it as a security measure is one of the most common ways a credential ends up somewhere it should not be. If you are working out how secrets should move through your system, an hour with a senior engineer is the cheap version of that lesson.

Talk to an engineer from ₹549/hr