URL Encode / Decode

Percent-encodes text or URLs as UTF-8 and decodes %XX sequences back to text, listing the query parameters of a decoded URL.

Loading…

How to use

  1. Choose Encode or Decode.
  2. Under Input, choose Component (value) for a single value such as one query parameter or path segment, or Full URL for a whole address.
  3. Type or paste into the box. The result updates as you type.
  4. When decoding, if the result contains a ?, the part after it (up to any #) is listed in a Query parameters table with Name and Value columns.
  5. Press Copy to copy the result, or Swap to move the result into the input and switch direction.

Frequently asked questions

Is my text sent to a server?
No. Encoding and decoding happen in your browser.
Component or full URL — which should I pick?
Component (value) encodes everything except letters, digits and - _ . ! ~ * ' ( ), so / ? & = # + are encoded too; use it for a single value. Full URL also keeps the characters that give a URL its structure (; , / ? : @ & = + $ #) besides letters, digits and - _ . ! ~ * ' ( ), and encodes spaces, non-ASCII letters and the rest.
Is a space encoded as %20 or +?
Encoding always writes a space as %20. When decoding, Component mode reads + as a space, as in HTML form data; Full URL mode reads + as a space only in the query (after ?) and keeps a + in the path as is. In a query, a literal plus sign must be written as %2B.
How are non-English characters handled?
They are encoded as UTF-8 bytes, so é becomes %C3%A9. Decoding expects UTF-8 too: a % that is not followed by two hex digits, or bytes that do not form valid UTF-8, show “Contains an invalid % sequence.”
Why did Full URL leave %2F or %26 undecoded?
In Full URL mode, escapes of characters that structure a URL, such as %2F (/), %3F (?), %26 (&), %3D (=) and %23 (#), are kept as they are, as decodeURI does. Choose Component (value) to decode them as well.