Percent-encode a URL or query value, or decode one back to readable text, instantly in your browser. URL encoding replaces unsafe characters (spaces, &, ?, #) with %-codes so links and parameters survive transmission intact. The table below lists the most common character encodings.
| Character | Encoded |
|---|---|
| space | %20 |
| ! | %21 |
| # | %23 |
| $ | %24 |
| & | %26 |
| + | %2B |
| / | %2F |
| : | %3A |
| = | %3D |
| ? | %3F |
| @ | %40 |
URL encoding (also called percent-encoding) converts characters into a format that can be safely transmitted within URLs. Special characters are replaced with a '%' followed by their hexadecimal value, e.g. a space becomes '%20'.
encodeURI encodes a full URI but preserves characters like ':', '/', '?', '&', '=' that have special meaning in URLs. encodeURIComponent encodes everything except letters, digits, and a few symbols (-_.!~*'()), making it ideal for encoding query parameter values.
Use URL encoding whenever you include user-supplied data in URLs, such as search queries, form data, API parameters, or any text that might contain special characters like spaces, ampersands, or non-ASCII characters.
Both represent a space character. '%20' is the standard percent-encoding used in URLs, while '+' is used in the application/x-www-form-urlencoded format (commonly used in HTML form submissions). Most servers accept both.
Yes. Non-ASCII characters (like accented letters, CJK characters, or emoji) are first encoded to UTF-8 bytes, then each byte is percent-encoded. For example, 'é' becomes '%C3%A9'.
A query string is the part of a URL that follows a '?' character. It contains key-value pairs separated by '&', e.g. '?name=John&age=30'. Each key and value should be URL-encoded to handle special characters.
URL encoding utilizes JavaScript's encodeURIComponent() method, which converts special characters into percent-encoded sequences according to RFC 3986 standards. Characters like spaces become %20, ampersands become %26, and non-ASCII Unicode characters are first converted to UTF-8 byte sequences, then each byte is hex-encoded with a percent prefix. Decoding applies decodeURIComponent() to reverse this process, handling malformed sequences gracefully. The tool differentiates between component encoding (for query parameters) and full URI encoding (for complete URLs), applying appropriate escaping rules to preserve URL structure while safely encoding user data.