How to use Query String Parser
- Paste a query string or a full URL.
- Inspect the parameter table (position, key, value, bracket path, raw form) and the JSON view.
- Pick the array style and encoding your API expects and copy the rebuilt query string.
Query String Parser features
- Parses ?, & and ; separated parameters with percent- and plus-decoding
- Repeated keys become arrays; key[] and key[a][b] bracket notation becomes arrays and nested objects
- Optional type detection (numbers, booleans, null) in the JSON view
- Rebuilds the query in four array styles (repeat, brackets, indices, comma) and two encodings (RFC 3986, form)
- Shows the original order re-encoded alongside the structured rebuild, with optional key sorting
- Accepts a full URL and extracts only the query part
Query String Parser example
Parse bracket arrays and rebuild with repeated keys
Input:
?tags[]=new&tags[]=sale&filter[price][max]=50&q=caf%C3%A9+latteOutput:
JSON: {"tags":["new","sale"],"filter":{"price":{"max":50}},"q":"café latte"}
Rebuilt (repeat style): tags=new&tags=sale&filter%5Bprice%5D%5Bmax%5D=50&q=caf%C3%A9%20latteFrequently asked questions about Query String Parser
How are repeated keys handled?
ids=1&ids=2 becomes an array ["1","2"] in the JSON view, and both entries stay visible in the table with their position. The rebuilt query uses the array style you select (repeat, brackets, indices or comma).
What does filter[price][max]=50 turn into?
Nested objects: {"filter":{"price":{"max":"50"}}}. Keys ending in [] become arrays, exactly as PHP, Rails and the qs library interpret them.
What is the difference between %20 and + for spaces?
RFC 3986 percent-encodes a space as %20. HTML form encoding (application/x-www-form-urlencoded) uses +. Both are decoded as a space when parsing; choose the encoding your API expects when rebuilding.
Can I paste a full URL?
Yes. When the input looks like a URL, only the part after ? is parsed and the fragment (#…) is ignored.
Technical notes
Decoding uses decodeURIComponent after turning + into spaces, falling back to the raw text for malformed sequences instead of throwing. Bracket paths are parsed with a small grammar (name followed by [segment]* ) matching PHP and the qs library; numeric segments become array indices.