URL parser and query string parser
About URL Parser
This URL parser splits a full web address into the parts defined by the WHATWG URL Standard: scheme, credentials, host, hostname, port, path, query string and fragment. Use it to parse a long callback URL, debug an API request or read an unfamiliar link without picking apart ampersands and percent-encoded text by hand.
Query parameters are decoded and shown two ways: as an ordered list and as a grouped object. The ordered list keeps duplicate parameters visible, which a plain object would hide. You can sort keys for comparison or hide parameters with empty values.
Two more modes work on the query string alone. Query to JSON turns a query string into a JSON object, with optional type inference. JSON to query builds a form-encoded query string from a JSON object.
Runs in your browser with the built-in URL parser. Nothing is uploaded and the address is never fetched, so a private dev hostname or signed callback URL is safe to inspect. Remove secrets before you share the output with someone else.
How it works
Start with an absolute URL
Enter the full address, including a scheme such as https://, http:// or ftp://. A relative path would have to be resolved against a made-up base domain. Requiring an absolute URL avoids that and keeps the reported origin accurate.
Separate host, hostname and port
Host is the hostname plus any explicit port. Hostname is only the domain name or IP address. Origin combines scheme, host and port. The browser may drop default HTTP and HTTPS ports, so the parser also reports whether the URL uses a default port.
Inspect decoded and repeated query values
URLSearchParams applies standard percent decoding and turns plus signs in the query into spaces. Repeated keys stay separate in queryEntries and become arrays in the grouped query object. So ?tag=json&tag=tools keeps both values.
Review the path and fragment
The pathname is shown in its canonical form and also split into decoded segments. The hash is shown without the leading #. Browsers handle the fragment after navigation, and it is normally not sent to the server.
Parse a query string to JSON
Query to JSON accepts a bare query string, one that starts with ?, or a full URL. UTF-8 percent escapes and + as a space are decoded strictly, and repeated names become arrays. With Infer scalar types on, true, false, null and plain numbers become typed JSON values, while IDs with leading zeros stay strings.
Build a query string from JSON
JSON to query encodes each key and value, writing spaces as +. Arrays can repeat the name (tag=a&tag=b), add brackets (tag[]=a) or join values with commas. Nested objects are written as compact JSON text, since there is no standard for nested query strings.
Frequently asked questions
Does parsing a URL open it or send a request?
No. The tool only passes the text to the browser's URL parser. It does not visit the address, look up its hostname, download anything or send the URL to JsonKit.
Why must I include https:// or another scheme?
Without a scheme, text such as example.com/path reads as a relative path. Requiring a full address means the parser does not invent a base URL, and the scheme, origin, host and port are correct. Query to JSON mode does not need a full URL.
How are duplicate query parameters handled?
Every occurrence is kept in queryEntries in source order. In the grouped query object, a key that appears more than once becomes an array, so no value is overwritten.
Are percent-encoded values decoded?
Yes. Query keys, query values and path segments are decoded with standard browser rules. The canonical href and pathname are still shown, so you can compare encoded and decoded forms.
How do I convert JSON to a query string?
Pick JSON to query, paste a flat JSON object and choose how arrays are written. Turn on Sort parameter names when you need a stable order, for example to compare or sign URLs.
Is it safe to paste a signed or private URL?
Parsing is local and never contacts the URL. Signed URLs often carry credentials in the query string, though. Treat the output as sensitive and keep it out of public messages and issue trackers.
Learn more
Sources & last verified
We checked this tool's behavior and the claims on this page against the specifications below on . The tool runs in your browser, so the output you see is exactly what the engine produced.
Found a wrong result or an outdated claim? Report an error and we will check it again.