URL Encode / Decode
Encode and decode URL components.
All encoding and decoding happens locally in your browser, so your text and URLs never leave your device.
Need to inspect a URL's parts? Try the URL Parser.
About URL Encode / Decode
This url encode decode tool percent-encodes text for safe use in URLs and decodes an encoded component back into readable text, all processed locally in your browser. It mirrors JavaScript's encodeURIComponent and decodeURIComponent, escaping reserved characters such as /, ?, &, = and spaces so values stay intact inside query strings and paths. Developers, QA engineers and API testers reach for this url encoder and url decoder to build query parameters, debug callback URLs, inspect tracking links, and clean up copied addresses full of %20 and %3A sequences. Because it works on a single component rather than a whole URL, you get precise, predictable percent encoding for one value at a time. Everything runs on your device and nothing is uploaded to a server, so even private tokens and internal URLs stay local.
Features
- Percent-encodes text using encodeURIComponent semantics
- Decodes encoded components back to readable characters
- Escapes reserved characters like /, ?, &, = and spaces
- Clear error message when percent-encoding is malformed
- Handles full Unicode, including emoji and accented letters
- Switches between encode and decode in one place
- Copy the result with a single click
- Runs entirely in your browser
How to use the URL Encode / Decode
- Paste the text or encoded value into the input box.
- Choose Encode to percent-encode or Decode to convert it back.
- Read the converted result in the output area.
- Copy the output and drop it into your URL or code.
Example
Input
name=John Doe&city=São Paulo
Output
name%3DJohn%20Doe%26city%3DS%C3%A3o%20Paulo
Encoding a single component escapes =, &, spaces and accented characters.
Common errors & troubleshooting
- Decoding fails with an invalid input error. — A stray % or an incomplete hex pair (like %2 or %ZZ) cannot be decoded. Fix or remove the malformed percent sequence.
- A full URL gets over-encoded, escaping :// and slashes. — This tool encodes a single component, so it escapes / and ?. Encode only the individual query values, not the whole address.
- Spaces become %20 instead of +. — encodeURIComponent uses %20 for spaces. The + convention only applies to application/x-www-form-urlencoded form bodies.
- Plus signs in decoded form data stay as spaces unexpectedly. — Decoding does not turn + into a space. Replace + with %20 before decoding if the value came from a form-encoded body.
Frequently asked questions
- What is URL encoding and when do I need it?
- URL encoding (percent-encoding) replaces unsafe characters with %HH byte sequences so values survive inside query strings and paths. Use this url encode decode tool whenever a parameter contains spaces, &, =, / or non-ASCII text.
- Does the URL Encode / Decode tool encode a component or a whole URL?
- It encodes a single component, like encodeURIComponent, so characters such as / and ? are escaped. Encode each query value separately rather than the entire address.
- How do I fix a decode that failed?
- Decoding fails on malformed percent-encoding, such as a stray % or invalid hex digits. Correct or remove the bad percent sequence in the URL Encode / Decode input and try again.
- Does it handle Unicode and emoji?
- Yes. Multi-byte UTF-8 characters, accented letters and emoji are encoded into their correct percent-encoded byte sequences and decoded back accurately.
- Why are spaces shown as %20 instead of +?
- This tool follows encodeURIComponent, which encodes spaces as %20. The + form is specific to form-encoded request bodies, not general URL components.
- Is my input sent anywhere when I encode or decode?
- No. The URL Encode / Decode tool runs entirely in your browser, so your input never leaves your device and nothing is uploaded to a server.
Related tools
All ArrayKit tools