URL Encoder & Decoder
Encode special characters or decode percent-encoded strings instantly
Output
Quick Guide
- Paste a URL or string and click Encode to percent-encode it
- Paste a percent-encoded string and click Decode to restore it
- Uses
encodeURIComponent— encodes all special characters including&,=,?
What is URL Encoding?
URL encoding (also called percent-encoding) converts characters that are not allowed in a URL into a format that can be transmitted over the internet. Each unsafe character is replaced by a % followed by two hexadecimal digits.
Common Encoded Characters
| Character | Encoded | Description |
|---|---|---|
| Space | %20 | Spaces are not valid in URLs |
| & | %26 | Used as query string separator |
| = | %3D | Used to assign query values |
| ? | %3F | Starts query string |
| # | %23 | Fragment identifier |
| + | %2B | Alternative space encoding in forms |
encodeURI vs encodeURIComponent
- encodeURI — encodes a full URL, preserving
:/?#[]@!$&'()*+,;= - encodeURIComponent — encodes a URL component (query value, path segment), encoding almost everything including
&and=
This tool uses encodeURIComponent, which is correct for encoding individual parameter values.