URL Encoder / Decoder
Percent-encode or decode URL components.
Frequently asked questions
- What is percent-encoding?
- URLs can only contain a safe set of ASCII characters. Anything else — spaces, &, =, non-ASCII letters — is written as %XX where XX is the byte's hex code.
- Encode vs encodeURIComponent?
- This tool uses encodeURIComponent/decodeURIComponent, which escapes the broadest set of characters including &, = and ?. That is what you want when placing a value inside a query string.
- When should I use encodeURI instead of encodeURIComponent?
- encodeURIComponent escapes everything that could break a URL component, including &, =, ? and /. Use it for query values. encodeURI leaves URL structure characters intact and is meant for whole URLs; this tool intentionally uses the component variant.
- Why does a + sign stay when I decode?
- encodeURIComponent represents a space as %20, while HTML form encoding historically uses +. This tool follows encodeURIComponent semantics, so + is a literal plus, not a space. Replace + with %20 before decoding form-style query strings.
- Why does encoding a whole URL escape :// as well?
- encodeURIComponent is designed for a single component, so it escapes every reserved character, including : and /. If you only need to escape a query value, encode that value on its own and leave the rest of the URL intact.
About this tool
URLs may only contain a limited set of ASCII characters, so anything else — spaces, ampersands, equals signs, non-Latin letters — is written as percent-encoding (%XX). This tool encodes and decodes URL components with encodeURIComponent/decodeURIComponent, which is the correct pair for values placed inside query strings.
How to use it
- Paste the text or encoded value into the input field.
- Choose Encode to percent-escape it, or Decode to turn %XX sequences back into characters.
- Copy the output from the result panel.
- When decoding untrusted data, expect an error for stray % signs — they must be part of a valid escape sequence.
← All tools