Encode special characters for URLs or decode percent-encoded strings.
URL encoding (also called percent-encoding) converts characters that have special meaning in URLs into a form that web servers and browsers handle safely. Spaces, ampersands, quotes, non-ASCII characters, and reserved syntax all need encoding before they appear in a query string or path. Our URL encoder/decoder runs entirely in your browser.
Reserved characters such as ?, #, &, = and / have structural meaning in URLs. Embedding them as literal data would confuse the parser. Percent-encoding replaces each byte with %XX where XX is its hexadecimal value. For example a space becomes %20 and an ampersand becomes %26. UTF-8 encoded text uses several percent-encoded bytes per non-ASCII character.
Paste your raw text or your encoded URL string, choose Encode or Decode, and copy the result. The operation runs locally so no part of your URL is sent to any server — useful when the URL carries authentication tokens or personally identifiable information.
Double-encoding (encoding an already encoded URL) is one of the most common mistakes. Always decode first before re-encoding. Another pitfall is encoding the path separator "/" inside the path component, which can break routing on some servers. Encode each query parameter value separately rather than the whole URL at once.
encodeURI keeps URL syntax characters (such as / and ?) intact and only escapes obvious unsafe characters. encodeURIComponent escapes everything that is not strictly alphanumeric and is used for individual parameter values.
Usually because the original encoding was not UTF-8. Try interpreting the bytes as Latin-1 or the source language encoding.
In paths yes. In query strings the older form encodes a space as "+". Both are accepted by most servers but %20 is unambiguous.