Skip to main content
AltF Calculators

URL Encode / Decode

  • 100% private — nothing is uploaded
  • Instant, live results as you type
  • Free forever, no sign-up needed
  • Works even when you're offline

About URL Encode / Decode

URL (percent) encoding replaces characters that are unsafe or reserved in a URL — spaces, &, ?, =, #, non-ASCII letters — with a % followed by their hexadecimal byte values. It lets you put arbitrary text safely inside a web address or query string.

This tool encodes and decodes both ways, and offers two scopes: Component escapes reserved characters too (for a single query value), while Full URI leaves the structural characters of a complete URL intact.

How to use the URL Encode / Decode

  1. Choose Encode or Decode.
  2. Pick the scope: Component for a single value, or Full URI for a whole address.
  3. Type or paste your text; the result updates live.
  4. Copy the encoded or decoded output.

Good to know

  • Component mode (encodeURIComponent) escapes / ? : @ & = + $ # and space, so it is right for individual query-string values.
  • Full URI mode (encodeURI) preserves those reserved characters, so it is meant for encoding an already-structured URL, not a lone value.
  • A space becomes %20; in the query string it is sometimes shown as + instead, an older application/x-www-form-urlencoded convention.

Frequently asked questions about the URL Encode / Decode

Component or Full URI — which do I need?

Use Component when encoding one piece that goes inside a URL, like a search term. Use Full URI when you have a complete URL and only want illegal characters escaped without breaking its :// ? & structure.

Why is a space sometimes %20 and sometimes +?

Percent-encoding uses %20. The + sign for a space is a separate convention from HTML form submission (application/x-www-form-urlencoded) and only applies inside query strings.

Does decoding always succeed?

Only if the input is well-formed. A lone % or an incomplete escape like %2 is invalid and will report a malformed-URI error.