| Key | Value (Decoded) |
|---|
filter[key]=val).
A Uniform Resource Locator (URL) is a standardized string of characters conforming to RFC 3986 and the living WHATWG URL Specification. URLs uniquely identify web resources and communicate transmission parameters to web servers, microservices, and client-side single page applications (SPAs).
According to RFC 3986 §3, any absolute URI complies with the formal grammar:
scheme:[//[user:password@]host[:port]][/]path[?query][#fragment]
https, http, wss, ftp). Followed by :.user:pass@host:port):
postgres://user:pass@localhost:5432/db).api.example.com) or IP literal ([::1] or 192.168.1.1). Always canonicalized to lowercase./v1/search/products).?key=value&...): Non-hierarchical data payload serialized as ampersand-separated key-value pairs.#anchor): Client-side locator that is never transmitted to the web server in HTTP request headers. Utilized exclusively by the web browser for scrolling or frontend routing.Unlike JSON, which has strict syntax specifications for lists ([]) and maps ({}), the HTTP standard has no native concept of arrays or complex objects in query strings. Over time, three major conventions emerged:
| Pattern Convention | Query String Example | Server Framework Parser Behavior |
|---|---|---|
| Repeated Keys (Standard) | ?tags=api&tags=fast |
Node.js / Express parses as ["api", "fast"]. Python Django uses request.GET.getlist('tags'). |
| Bracket Array Notation | ?tags[]=api&tags[]=fast |
PHP ($_GET['tags']) and Ruby on Rails automatically cast into an array. |
| Bracket Object Notation | ?filter[active]=true&filter[role]=admin |
Parsed by Express qs into nested object { filter: { active: 'true', role: 'admin' } }. |
decodeURIComponent() before splitting by ? or &, any literal %26 (encoded &) or %3F (encoded ?) inside a query parameter value will be prematurely converted to actual delimiters, corrupting the parameter structure.application/x-www-form-urlencoded traditionally convert spaces to plus signs (+), whereas standard RFC 3986 URI paths use %20. Modern parsers treat + as a space in query strings.#) is strictly a client-side instruction for the browser's user agent. The browser strips the fragment before sending the HTTP request over the network.URLSearchParams parser. If a key appears multiple times, it aggregates the values into an array. If keys contain brackets (e.g. user[name]), it reconstructs nested JSON objects.