URL Decode
Decode percent-encoded URLs back to readable text.
What is URL Decode
URL decoding converts percent-encoded (%XX) strings back into their original characters.
🔒 Everything runs in your browser. Nothing is uploaded.
What this tool actually does with your file
- Where it runs
- In your browser, on this page
- Upload
- None — the file never leaves your device
- Offline
- Works with the network disconnected
The plus sign is the trap
decodeURIComponent deliberately does not convert + to a space, because + is a legal character. Form-encoded data does mean space by +. A decoder that always turns + into a space is correct for query strings and wrong for everything else — notably for Base64 values, which frequently contain + and would come back corrupted in exactly the place you would not look.
So the correct behaviour depends on where the string came from. If it was produced by an HTML form submission, decode + as space. If it came out of a JSON body, a path segment or a JWT, leave + alone. This tool exposes both modes because picking one silently is how data gets corrupted.
Isolated percent signs throw
decodeURIComponent raises URIError on a malformed sequence: a % not followed by two hex digits, or a truncated sequence at the end of the string. A literal 100% discount in a value is enough to trigger it. The fix is to encode the percent sign itself as %25 before decoding, or to decode with a tolerant routine that passes malformed sequences through unchanged.
Mixed encoding inside one string is the second case. If half the value is already decoded and half is not — common when a templating engine escapes a piece of an already-escaped URL — one pass yields a half-correct result. Run decoding repeatedly until the output stops changing, and if it never stops, the original was double-encoded on purpose and you should stop earlier.
Reading the result correctly
Percent-encoding describes bytes, not characters. When those bytes are not valid UTF-8 the decoded text contains U+FFFD, which means either the source used a different charset (Latin-1 and GBK both appear in old links) or the string was cut mid-character by a URL length limit.
For CJK content, a truncated link usually breaks on the last character only. If the tail is garbled but the rest is clean, the source was truncated, not mis-encoded — re-copy the full URL rather than trying other charsets.
How to use it
- 1.Enter encoded string
- 2.Decode
- 3.View result
How URL Decode works under the hood
Encoding tools convert between representations of the same bytes: Base64, percent-encoding, hex, HTML entities, Unicode escapes. A correct encoder is reversible; a lossy one silently changes the data.
- 1
Get the exact bytes
Text is encoded to UTF-8 bytes with TextEncoder first; binary input is read as an ArrayBuffer. Encoding the wrong byte sequence is the most common cause of a wrong result.
- 2
Apply the encoding rule
Each format has an exact specification: Base64 uses a 64-symbol alphabet with padding, percent-encoding escapes reserved characters as UTF-8 bytes.
- 3
Decode back to verify
Round-tripping the output back to the input is the only honest proof that an encoder is correct. The tool keeps the reverse path available on the same page.
Processing pipeline
Base64 is not encryption
Base64 increases size by about a third and hides nothing: anyone can decode it. It exists to carry binary data through text-only channels such as JSON, email headers and data URLs. If you need confidentiality, use encryption with a key, not an encoding.
Where encoders break
Percent-encoding applied twice turns %20 into %2520; Base64 without padding fails strict decoders; UTF-16 input decoded as UTF-8 produces replacement characters that cannot be recovered. When output looks wrong, check the byte sequence before checking the tool.
Verify it yourself
Encoders are pure functions over bytes. Decode the output again and you should get the input back exactly.
- 1.Open DevTools on this page and switch to the Network tab
- 2.Keep the filter on Fetch/XHR and run the tool
- 3.Confirm no request carries your file — you should see only page assets and fonts
Frequently asked questions
What is URL decoding?
It turns strings like %E6%97%A5 into the original characters.
Is it safe?
Yes, everything runs in your browser.
What this kind of conversion cannot keep
Encoding and hashing run through the browser's Web Crypto API or a pure-JavaScript implementation. The output is deterministic: the same input always produces the same digest, so you can verify a result against any other tool.
More in Encoding
On this page
- What is URL Decode
- What this tool actually does with your file
- How it actually behaves
- How to use it
- How it works inside
- Frequently asked questions
Excel formula reference
29 functions with syntax, arguments and a table you can retype.
Browse the list →