Percent triplets represent UTF-8 bytes
Unsafe characters are converted to UTF-8 and written as percent followed by two hexadecimal digits per byte. Non-ASCII characters can therefore produce several percent triplets.
Encode special characters for URLs or decode percent-encoded URL strings.
How to use
Enter the URL or string to encode or decode.
Select encode to percent-encode or decode to restore the URL.
Click copy to grab the encoded or decoded URL string.
The guide
Use this page for values that belong inside a URL, such as a query parameter, path segment, or fragment value. The encoder uses encodeURIComponent, which escapes reserved punctuation as well as spaces. It is intentionally stricter than encoding a complete URL because separators such as slash, question mark, ampersand, and equals may be data inside a component.
A concrete input and expected output from the current implementation.
Input
honey & tea
Expected output
honey%20%26%20tea
Each space becomes %20 and the ampersand becomes %26. Decoding the result returns the original eleven-character value.
Unsafe characters are converted to UTF-8 and written as percent followed by two hexadecimal digits per byte. Non-ASCII characters can therefore produce several percent triplets.
Encoding a whole URL with encodeURIComponent also escapes its structural separators. Enter only the value that needs escaping unless you deliberately want the complete URL represented as data.
Ampersand separates query parameters in a URL. Encoding it as %26 keeps it inside one parameter value instead of starting another parameter.
Inside one path segment, usually yes. Between path segments, no. Decide whether the slash is data or part of the URL structure before encoding.
The example and behavioral notes were checked against the browser implementation. Standards and primary references below define the relevant format, formula, or platform behavior.
Sent. Thank you.