Skip to content
TR ToolRux

URL Encoder / Decoder

Encode special characters for safe URLs or decode percent-encoded strings back to readable text — supports both encodeURI and encodeURIComponent.

Encodes all special characters including : / ? # [ ] @ ! $ & ' ( ) * + , ; =

📖 Learn More

Everything you need to know

What is URL Encoding?

URL encoding (also called percent-encoding) replaces characters that aren't allowed in URLs with a % followed by their hexadecimal ASCII code. For example, spaces become %20, ampersands become %26, and angle brackets become %3C and %3E.

Two Encoding Methods

This tool supports both JavaScript URL encoding methods:

  • encodeURIComponent — Encodes all special characters. Use this for query parameter values, form data, and any string you're embedding inside a URL.
  • encodeURI — Preserves URL-structural characters like :, /, ?, #, @. Use this when encoding a complete URL while keeping its structure intact.

Common Use Cases

URL encoding is essential for building API query strings, passing user input in URLs, encoding redirect URLs, creating mailto links with special characters, and embedding data in QR codes or deep links.

Decode Percent-Encoded URLs

Switch to decode mode to convert percent-encoded strings back to readable text. Useful for debugging API responses, reading server logs, and understanding encoded redirect chains.

Related Tools

Encode data for APIs with the Base64 Encoder, test URL patterns with the Regex Tester, or format API responses with the JSON Formatter.