Quick answer
A query parameter is an entry in the query part of a URL. The query begins after a question mark, and parameters commonly use a name=value form separated by ampersands.
Original example
One name can appear more than once
In https://example.com/search?tag=image&tag=web&level=beginner, the ordered query entries are tag=image, tag=web, and level=beginner. Keeping both tag entries matters; converting them to a plain one-value object would lose information.
How browsers expose query values
URLSearchParams provides the query as an ordered sequence of entries. Names may repeat and values may be empty.
Query decoding follows form-style rules: a plus sign becomes a space, while %2B represents a literal plus sign. The raw query text and the decoded entries are therefore different views.
Common misunderstandings
- Repeated query names are valid and should not automatically be collapsed into one value.
- A query parameter is not the same as the fragment that begins with #.
Related answers
Sources
- URLSearchParams - MDN Web Docs, accessed 2026-10-29
This is an unreviewed preview draft. Corrections can be sent after the owner configures a verified contact address.