tools / url-encode

URL Encoder / Decoder

Percent-encode text for safe use in URLs, or decode an encoded URL back to plain text. Everything runs in your browser.

Input
Output

What is URL encoding?

URL encoding (percent-encoding) replaces characters that aren't safe in a URL — spaces, &, ?, #, non-ASCII letters, and more — with a % followed by the character's hex byte value. This keeps URLs and query strings unambiguous, since reserved characters like & and = normally separate query parameters.

When do you need this?

  • Building a query string parameter that contains spaces, symbols, or another URL
  • Passing a redirect URL or search term through another site's link
  • Debugging a link that isn't working because of unescaped characters
  • Decoding a long, unreadable percent-encoded URL to see what it actually contains

Frequently asked questions

What's the difference between encodeURIComponent and encodeURI?

This tool uses encodeURIComponent, which escapes every reserved character including &, =, and ? — correct for encoding a single query parameter value. encodeURI leaves those characters alone because it expects a full URL, not one piece of it.

Why does a space become %20 or +?

%20 is the standard percent-encoded space. + is an older convention specific to application/x-www-form-urlencoded form data — this tool always outputs %20.

Is my data uploaded when I use this tool?

No. Encoding and decoding both happen instantly in your browser using built-in JavaScript functions — nothing is sent to a server.