🔒

URL Safe Base64

URL-safe Base64 encoding that replaces +/= with -_~ for URLs

Input
Result
🔒 All processing runs in your browser. Your data is never sent to any server.

📖 What is this tool?

URL Safe Base64 encodes and decodes using a modified Base64 alphabet that replaces + with -, / with _, and removes = padding. This variant is safe to use in URLs and filenames without requiring percent-encoding.

💡 Example

Input
Hello World+/=
Output
SGVsbG8gV29ybGQrLz0 (no +, /, or = characters)

🛠️ Common Use Cases

  • Encode data for use in URL parameters
  • Generate URL-safe tokens for authentication
  • Decode JWT token components
  • Encode binary data for API transmission
  • Create file-safe encoded strings

❓ Frequently Asked Questions

What is the difference between Base64 and URL-safe Base64?
Standard Base64 uses +, / and = which have special meanings in URLs. URL-safe Base64 replaces + with -, / with _ and removes trailing = padding, making it safe for URL parameters.
Where is URL-safe Base64 used?
JWT tokens, OAuth state parameters, and many web APIs use URL-safe Base64. The JWT standard specifically requires URL-safe Base64 for encoding headers and payloads.
Can I decode URL-safe Base64 with standard Base64 tools?
Yes — just replace - back with + and _ back with / before decoding. Most Base64 libraries have a URL-safe mode that handles this automatically.
🔒
Your data stays private. All processing happens entirely in your browser. Nothing is ever sent to our servers. You can use this tool offline after the page loads.