Repeated URL keys carry multiple selections. Reading a single value can silently discard filters chosen by the visitor.
Worked example
console.log(new URLSearchParams("tag=js&tag=web").getAll("tag"));Result
[ 'js', 'web' ]Implementation notes
Search parameter order can carry meaning for priority lists. Avoid converting directly to an object when duplicates or insertion order form part of the request.
Try it yourself
Try the same key twice, then repeat it with an empty value.
Open the JavaScript example →Editorial date May 27, 2026 · Published December 6, 2026