All tools
Developer

URL Encode/Decode

Percent-encode or decode a URL component using the real RFC 3986 rules.

🔒 Runs entirely in your browser — nothing here is ever uploaded

About the URL Encode/Decode

Percent-encodes or decodes a single URL component (a query parameter, form field, or path segment) using the real encodeURIComponent/decodeURIComponent rules a browser applies — not the legacy, Unicode-broken escape/unescape functions.

100% Free Runs in Your Browser No Sign-Up Required
How to use it
  1. Choose Encode or Decode.
  2. Paste your text or encoded string.
  3. Read the result, and copy it with the copy button.
Formula
Encode: JavaScript's built-in encodeURIComponent (RFC 3986 percent-encoding). Decode: decodeURIComponent, the exact inverse.
Worked example

Encoding "hello world & more?=test" produces "hello%20world%20%26%20more%3F%3Dtest"; decoding that string returns the exact original.

Interpreting your result

This encodes/decodes one component/value, not a full URL — encoding a full URL needs encodeURI instead, which leaves reserved characters like / and : untouched so the URL structure survives. A malformed percent-sequence on decode is caught and shown as a clear error rather than crashing.

Recommendations
  • Use this for one query-string value or form field, not a whole URL.
  • Spaces become %20, not + — that's the query-string convention, not this component-encoding standard.
  • A decode error almost always means the string wasn't actually percent-encoded, or was truncated.
Frequently asked questions
escape/unescape are legacy functions that don't correctly handle non-ASCII (Unicode) characters and are deprecated — encodeURIComponent/decodeURIComponent are the modern, correct standard.
Sources