Skip to content
Kitvoo

URL encoder

Encode and decode

Input

Result

What you enter is never sent to a server. Everything is processed in your browser on this device.

How to use

  1. Under Direction, choose Encode or Decode.
  2. Under Method, choose encodeURIComponent or encodeURI.
  3. Type or paste in the input box and the result appears right away. Press Use result as input to run the result through again.
  4. Turn on Show query as table to see each URL parameter on its own row.

FAQ

What’s the difference between encodeURIComponent and encodeURI?

encodeURIComponent also encodes separators such as / ? & = #, so use it for a single parameter value. encodeURI leaves the characters that make up a URL’s structure alone and only encodes things like spaces and non-ASCII text, so use it for a whole URL. Using encodeURI on a single value can leave & or = in place and break the query.

Why are spaces encoded as %20 instead of +?

Encoding always turns spaces into %20. When decoding form data or query strings where spaces were written as +, turn on Treat + as space. That option only appears when decoding.

It says something isn’t a valid % escape.

Either a % isn’t followed by two hex digits (like %zz or a % at the very end), or a run of % values doesn’t form valid UTF-8. The message shows roughly which character position, so check whether that part was cut off. Strings encoded in legacy, non-UTF-8 character sets also fail here.

How does Show query as table work?

Paste a full URL, ?a=1&b=2, or just a=1&b=2, and each key and value is decoded into a table. Anything after # is ignored, and repeated keys are all listed in order. In the table, + is read as a space.