CalculatorsConvertersDeveloperTextAll toolsDirectory
Submit your tool Sign in
Theme
Home/Answers/Developer
How-to

How do I parse a URL query string into key-value pairs?

Short answer

Paste a URL or a query string into a browser-based query string parser and it breaks it into a readable table of parameter names and values, decoding any percent-encoding along the way. It runs on your device, so a URL carrying tokens, search terms or user ids in its parameters is never uploaded.

Why a long query string is hard to read

The part of a URL after the question mark is a run of key=value pairs joined by ampersands, and once values are percent-encoded and there are several parameters it becomes a wall of text. A parser splits it on the ampersands and equals signs, decodes each value, and lays the result out as a clean list so you can see exactly what the URL is carrying.

Handy for debugging and privacy

Reading a query string is a common step when debugging redirects, analytics links, OAuth callbacks and tracking parameters. Seeing the decoded parameters also makes it obvious when a URL is carrying more than you expected, like a token or an email address. Because the parsing is local, you can safely inspect a URL from a private system, and a companion encoder handles building or decoding individual values.

Step by step

  1. Paste the URL. Paste the full URL or just the query string into the parser.
  2. Parse locally. The tool splits and decodes the parameters in your browser.
  3. Read the parameters. Review the name and value of each parameter in the list.

Frequently asked questions

Does it decode percent-encoding?

Yes. Encoded values like %40 are decoded, so you see the readable value such as an at sign.

Can I paste a whole URL?

Yes. The parser takes the part after the question mark, so a full URL or a bare query string both work.

Is the URL sent to a server?

No. Parsing happens entirely in your browser.

Related answers