Guides

Base64 vs Base64URL: avoid decode failures

Differences, common pitfalls, and why JWT uses Base64URL.

Related tools

Tip: open the tool page to see Pro batch/advanced modes.

What’s the difference?

Base64URL is a URL-safe variant of Base64: `+` → `-`, `/` → `_`, and padding `=` is often omitted.

JWT header/payload segments are Base64URL, so decoding them with standard Base64 often fails or looks wrong.

Debug checklist

Remove whitespace/newlines first (hidden characters commonly break decoding).

If you see `-` or `_`, treat it as Base64URL.

If length isn’t a multiple of 4, add `=` padding (or use a tool that auto-pads).