A value inside a query string
- Input
- a/b?c=d
- Output
- a%2Fb%3Fc%3Dd
Component mode escapes the slash, question mark and equals sign. Without this, everything after the first ampersand becomes a separate parameter and your value is truncated.
URL encoding replaces characters that have a special meaning in a web address with a percent sign and their byte value, so a value containing a slash or an ampersand does not break the URL around it. The part most tools leave out is that there are two different jobs here — escaping a whole URL and escaping one value inside it — and using the wrong one is the usual cause of a link that silently loses half its parameters.
Runs entirely in your browser — nothing you paste is uploaded.
How to
Choose component for a single value, full URL to escape an address while keeping its structure, or form for data sent as application/x-www-form-urlencoded.
Enter the value or URL. The result appears as you type, and switching modes updates it immediately so you can compare.
When the input parses as a URL, its scheme, host, path, query parameters and fragment are listed separately so you can see which part needs escaping.
Copy the encoded or decoded text. Decoding reports malformed sequences rather than silently returning something wrong.
Examples
Component mode escapes the slash, question mark and equals sign. Without this, everything after the first ampersand becomes a separate parameter and your value is truncated.
Full-URL mode escapes the space but leaves the scheme, slashes and colon intact. Component mode would escape those too and produce a string no browser could follow.
HTML forms encode a space as a plus sign rather than %20, and escape a few punctuation characters that percent-encoding leaves alone. Decoding form data with the wrong mode leaves stray plus signs in your text.
Why use it
Each mode says what it escapes and when to use it, which is the actual difficulty — the encoding itself is trivial once you have chosen correctly.
Query parameters are listed as key and value pairs, so you can see exactly which value contains the character causing trouble.
Non-ASCII characters are encoded as their UTF-8 bytes, which is what every modern server expects.
A stray percent sign produces a clear explanation rather than an unhandled exception, which is how most decoders fail.
Good to know
Summary
FAQ
Discover