How URL query strings are structured and encoded
The parts of a query string, how percent-encoding and the plus sign work, and why the same key can appear more than once.
The shape of a query string
A query string is the part of a URL that follows the question mark. It is a list of key and value pairs, each written as key=value and separated by an ampersand. The whole thing carries state that the page did not put in the path, such as a search term, a sort order, or a tracking tag. Because it is just text glued onto the end of a URL, small mistakes in punctuation or encoding are easy to make and hard to spot by eye, which is exactly where a parser earns its keep.
Why encoding exists
Some characters have a job inside a URL. The ampersand separates pairs, the equals sign splits a key from its value, and the question mark starts the query. If your actual data contains one of those characters, it has to be escaped so a reader does not mistake it for punctuation. Percent-encoding solves this by writing a byte as a percent sign followed by two hex digits, so a space becomes %20 and an ampersand inside a value becomes %26. Decoding reverses that, turning the escapes back into the real characters you meant.
The plus sign puzzle
Older HTML forms encoded a space as a plus sign rather than %20, a convention that lives on in countless links and server frameworks. That creates ambiguity: a plus in a query string usually means a space, not a literal plus. When this tool reads a query it treats a plus as a space to match browser behavior, and when it builds one it uses %20 so the output is unambiguous. If you truly need a literal plus in a value, encode it as %2B before pasting.
Repeated keys and arrays
Nothing stops a key from appearing several times, and many sites rely on it to send a list, for example two tag parameters that together mean two tags. There is no single official rule for collapsing repeats, so different servers treat them differently. This tool keeps every occurrence visible in the pair table and, in the JSON view, gathers repeats of the same key into an array while leaving single keys as plain strings, which is the most common and least surprising interpretation.