How to use
- 1Paste text or a URL and choose encode or decode.
- 2Pick component mode (encodeURIComponent) for a single value or full-URL mode (encodeURI).
- 3Use the URL parser to see protocol, host, path and each query parameter.
- 4Edit parameters in the table; the URL is rebuilt automatically.
What URL encoding does
URLs may only contain a limited set of ASCII characters (RFC 3986). Everything else is percent-encoded as % followed by the hex value of each UTF-8 byte: a space becomes %20, & becomes %26, é becomes %C3%A9. Encoding is essential when a value contains characters with special meaning in URLs — &, =, ?, #, / — or it will break the URL structure.
encodeURIComponent vs encodeURI
encodeURIComponent encodes everything except letters, digits and - _ . ! ~ * ' ( ), so use it for individual query values or path segments: q=rock%20%26%20roll. encodeURI leaves URL structure characters (: / ? # & =) intact, so use it on a complete URL that just contains spaces or non-ASCII characters. Using encodeURI on a parameter value is a classic bug — an & inside the value would split it into two parameters.
Debugging with the URL parser
Long tracking URLs from ads, emails and affiliates are hard to read. The parser splits a URL into protocol, host, path and a decoded key/value list of query parameters, so you can spot duplicated or malformed UTM tags, remove parameters, or change values and copy the rebuilt URL. Note that in HTML form submissions spaces are often encoded as + instead of %20.
Frequently asked questions
Why is a space sometimes + and sometimes %20?
HTML form encoding (application/x-www-form-urlencoded) uses + for spaces in query strings; standard percent-encoding uses %20. %20 is valid everywhere, + only in query strings.
How do I decode a URL with %20 and %3A?
Paste it and choose decode. %20 becomes a space, %3A a colon, and so on.
Why does my URL get double-encoded (%2520)?
An already-encoded value was encoded again, turning % into %25. Decode once, then encode only the raw value.
Not happy with the results?
Talk to Webin Agency about fast, SEO-friendly websites, e-commerce and Google Ads management.