Common encoded characters
| Character | Encoded | Character | Encoded |
|---|---|---|---|
| space | %20 | & | %26 |
/ | %2F | = | %3D |
? | %3F | # | %23 |
+ | %2B | @ | %40 |
: | %3A | % | %25 |
In JavaScript, encodeURIComponent() matches “Encode component” and encodeURI() matches “Encode full URL”.
Encode or decode text for URLs, and break any URL into its parts and query parameters.
| Query parameter | Value (decoded) |
|---|
| Character | Encoded | Character | Encoded |
|---|---|---|---|
| space | %20 | & | %26 |
/ | %2F | = | %3D |
? | %3F | # | %23 |
+ | %2B | @ | %40 |
: | %3A | % | %25 |
In JavaScript, encodeURIComponent() matches “Encode component” and encodeURI() matches “Encode full URL”.
URL encoding (percent-encoding) replaces characters that aren't allowed or have a special meaning in URLs with a % followed by two hex digits. A space becomes %20, & becomes %26 and é becomes %C3%A9 (its UTF-8 bytes).
Encode a component (a single query value or path segment) in almost all cases; this escapes /, ?, & and = so they can't break the URL. Use full-URL mode only to clean up a complete address that contains spaces or non-ASCII characters while keeping its structure.
HTML forms encode spaces in query strings as +. Both are valid in that position. The decoder treats + as a space when “Treat + as space” is checked.
No. Encoding, decoding and URL parsing all happen in your browser.