HandyBench

URL Encoder & Decoder

Percent-encode and decode URLs.

How to use the URL Encoder & Decoder

  1. 1 Paste a URL or string.
  2. 2 Choose encode or decode (whole URL or component).
  3. 3 Copy the result.

Frequently asked questions

What is the difference between encodeURI and encodeURIComponent?

encodeURI keeps URL structure characters like / and ? intact, while encodeURIComponent escapes them too — use the latter for query-string values.

Why does a space become %20 or +?

In a URL path a space is percent-encoded as %20. In a query string it can also appear as a + sign. Use the component option to encode query values the way servers expect.

When do I need URL encoding?

Whenever a value contains characters outside the unreserved set — spaces, &, ?, #, =, / or non-ASCII text — encode it before putting it in a URL so it is not misread as URL structure.