Overview
Introduction
A JSON value pulled from a URL's query string arrives percent-encoded, its braces, quotes, and colons replaced with %XX sequences, and needs decoding before it's readable. This tool decodes it and validates the result in one step.
That combination matters because a successful percent-decode doesn't guarantee the decoded text is actually valid JSON; this tool checks both.
What Is JSON URL Decoder?
A URL decoder scoped to JSON: it reverses percent-encoding with decodeURIComponent(), then parses and pretty-prints the resulting text as JSON.
It's the exact mirror of URL-encode JSON, restoring a percent-encoded query parameter back to a readable document.
How JSON URL Decoder Works
The tool passes your input to decodeURIComponent(), which converts every %XX sequence back to its original character, then attempts to parse the decoded text as JSON.
If either step fails, decoding malformed percent-encoding or parsing invalid JSON, a specific error is shown so you know which stage the problem is in.
When To Use JSON URL Decoder
Use it when debugging a URL parameter that carries JSON-shaped application state and you need to see the actual data.
It's also useful when verifying that a URL-encode JSON encoding round-trips correctly before shipping a shareable link.
Often used alongside JSON URL Encoder, Base64 to JSON Converter and JSON Formatter & Beautifier.
Features
Advantages
- Decodes and validates as JSON in one step, catching problems at either stage.
- Matches the browser's own decodeURIComponent() behavior exactly.
- Pretty-prints the result automatically for readability.
Limitations
- Expects just the encoded value, not a full query string with parameter names and ampersands.
- Doesn't recover data if the original percent-encoding was already corrupted before you copied it.
Examples
Best Practices & Notes
Best Practices
- Copy only the value portion of a query parameter, not the leading '?' or 'key=' prefix.
- If decoding fails, check for a stray literal % character not followed by two hex digits.
- Re-validate decoded data on the server too; never trust client-supplied query parameters blindly.
Developer Notes
Decoding is a direct decodeURIComponent(input) call wrapped in a try/catch, since malformed percent sequences (like a trailing lone %) throw a URIError; the result is then run through JSON.parse() with the standard error-location logic shared across this category's tools.
JSON URL Decoder Use Cases
- Inspecting JSON-shaped state carried in a shared link's query string
- Debugging an API request built with a URL-encoded JSON parameter
- Verifying a URL-encode/decode round trip during development
Common Mistakes
- Pasting the whole query string including '?' and other parameters instead of just the target value.
- Assuming a successful decode means valid JSON; the two are checked separately.
- Double-decoding a value that was already decoded by the browser or framework.
Tips
- If you're not sure whether a value is already decoded, try validating it as JSON directly first.
- Pair with URL-encode JSON to confirm symmetric encode/decode behavior.