URL Encoder
URL-encode and decode with one click.
Output
https%3A%2F%2Fexample.com%2Fpath%3Fq%3Dhello%20world%26category%3Dtools
About URL Encoder
URL encoder/decoder that runs locally.
How to use
- 1Pick Encode or Decode.
- 2Choose Component or Full URI mode.
- 3Paste input, copy output.
URLs have rules about which characters are safe. Letters, digits, and a small set of unreserved characters (`-`, `.`, `_`, `~`) pass through untouched. Everything else gets percent-encoded: space becomes `%20`, `?` becomes `%3F`, `&` becomes `%26`. This encoder handles the rules correctly, including the often-missed distinction between encoding a full URL and encoding just a URI component.
Component vs full URI
`encodeURIComponent()` encodes aggressively — it encodes `/`, `?`, `&`, `=`, and `#` because those characters have special meaning inside URLs but should be literal inside a query parameter value. `encodeURI()` is more permissive — it leaves `/`, `?`, `&`, `=`, and `#` alone because they're structural to the URL itself. Use component encoding when you're building a query string value. Use full-URI encoding when you have an entire URL with unsafe characters in the path (rare, but happens with internationalised paths). When in doubt, use component encoding — it's safer to over-encode than under-encode.
Frequently asked questions
Quick answers to the questions people actually ask about URL Encoder.
When do I use Component encoding vs Full URI encoding?
When do I use Component encoding vs Full URI encoding?
Component when you're building a single query parameter value, path segment, or fragment — anywhere the input shouldn't contain URL structural characters. Full URI when you have an entire URL with unusual characters in the path. In practice, component encoding is what you want 90% of the time.
What about pluses in encoded form data?
What about pluses in encoded form data?
`application/x-www-form-urlencoded` (the format browsers use for form submissions) encodes spaces as `+`, not `%20`. Standard URL encoding uses `%20`. They're not the same. If you're encoding for a form body, encode then replace `%20` with `+`. If you're encoding for a URL, leave it as `%20`.
Does it handle multi-byte characters?
Does it handle multi-byte characters?
Yes. UTF-8 bytes are encoded individually — a single emoji becomes 4 percent-encoded byte sequences. Decoding reverses it cleanly.