Base64URL Encoder
Base64URL Encoder
Encode UTF-8 text to Base64URL safe output.
InputsManual input27 charsAuto run
File input
Choose a file
Click, drop, or paste from clipboard.
Options
0
No options.
More actions
Manual
Base64URL output
0
No output yet.
Live
Manual
Ready
27
Input
0
Output
0
ms
Flow
- Encode UTF-8 text to standard Base64 first.
- Replace + with - and / with _.
- Trim trailing padding equals signs.
Example
Worked example: JWT-like header payload
- 1 Input = {"alg":"HS256","typ":"JWT"}
- 2 Text is encoded to Base64 and converted to URL-safe alphabet.
- 3 Padding is removed for compact token segment output.
Output is a valid Base64URL segment safe for token composition.
How
- Paste text input into the editor.
- Run encoding to generate Base64URL output.
- Copy output and use it in token or URL workflows.
Cases
- Generate JWT header and payload segments for local testing.
- Create URL-safe payload parameters in frontend apps.
- Convert Base64 text into URL-compatible representation.
Avoid
- Comparing Base64URL output to standard Base64 without accounting for alphabet differences.
- Adding padding manually when target format expects trimmed output.
- Using this output in systems that require standard Base64 with padding.
FAQ
What makes Base64URL different from Base64?
Base64URL uses - and _ instead of + and / and commonly removes trailing padding equals signs.
Is this useful for JWT generation?
Yes, JWT header and payload segments use Base64URL encoding.
Can I decode this with the standard Base64 decoder?
Use the Base64URL Decoder tool to avoid normalization issues.
Switch
Switch12
No match.