URL Encode / Decode
Percent-encode text for use in a URL, decode encoded strings, and see any URL broken into its parts and query parameters.
URL inspector
Key facts
- Privacy
- Runs in your browser: your files and text are never uploaded
- Last updated
How to URL-encode text
Paste the text you want to put in a URL, such as a search term or a parameter value, and copy the encoded result. To read an encoded link, switch to Decode. The URL inspector splits any address into protocol, host, path and each query parameter, already decoded.
Frequently asked questions
What is URL encoding?
URLs can only contain certain characters. Others are replaced by % followed by their byte value in hex: a space becomes %20 and é becomes %C3%A9.
Component or full URL: which should I use?
Use Component (encodeURIComponent) for a single value such as a search term or parameter, because it also encodes / ? & and =. Use Full URL (encodeURI) for a whole address, which keeps those characters.
Why do spaces sometimes become +?
HTML forms encode spaces as + in query strings. Both + and %20 are common; the decoder treats + as a space by default.
Which characters need to be URL encoded?
Everything except letters, digits and the four unreserved characters - _ . ~ should be encoded in a URL component. Characters such as space, &, ?, #, / and = have special meanings in URLs, and non-English letters are encoded as UTF-8 bytes.
What does %20 mean in a URL?
It’s an encoded space. %20 is the hexadecimal code for the space character (32). In form data you’ll sometimes see + used for a space instead.
Sources
The rules and figures this tool uses come from:
Related tools
- JSON FormatterPretty-print, validate and minify JSON
- Hash GeneratorMD5, SHA-1, SHA-256 and SHA-512 for text and files
- JWT DecoderInspect header, payload, expiry and signature
- Regex TesterTest patterns with live match highlights
- Unix Timestamp ConverterEpoch time to dates and back
- Binary ConverterBinary, decimal, hex and octal, two’s complement and text to binary
- Base64 Encode / DecodeText and files to and from Base64
- UUID Generatorv4 and v7 UUIDs in bulk