npm / qs
qs
What changed in qs 6, from its official release notes, upgrade guides and advisories. Also covers @types/qs. Sources checked 2026-10-19.
8 breaking5 security2 new APIs and options1 performance2 behavior and defaults24 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initqs 642 changes
Breaking changes 8
The [] sequence is treated as array syntax only when it ends the key.
Enforces arrayLimit on comma groups under []= when throwOnLimitExceeded is set.
allowEmptyArrays no longer skips cycle detection or drops own keys on an empty array with own properties.
Throws the arrayLimit error before splitting oversized comma values.
Enforces throwOnLimitExceeded when arrays grow cumulatively through combine or merge.
Handles nested bracket groups; output changes for some unbalanced bracket keys.
arrayLimit is now enforced on values parsed using comma notation.
With throwOnLimitExceeded enabled, parse now throws when indexed notation exceeds arrayLimit.
Security 5
Does not invoke a non-callable constructor.isBuffer.
Avoids invoking the __proto__ setter when copying own properties.
Skips null/undefined entries in comma-format arrays when encodeValuesOnly is enabled, instead of crashing in the encoder.
Fixes
parameterLimit: InfinitywiththrowOnLimitExceeded: truesilently dropping all parameters.Ensure arrayLimit applies to [] notation as well.
New APIs and options 2
Adds a depth option to bound recursion depth; its default is Infinity.
Adds the strictMerge option to wrap object/primitive conflicts in an array.
Performance 1
Decoders are skipped when the input contains no percent sign.
Behavior and default changes 2
Date values are serialized when a filter is provided.
Indexed notation exceeding arrayLimit now marks overflow objects.
Fixes and other changes 24
parse no longer mutates an object input.
Only top-level dots are converted to brackets when allowDots is enabled.
arrayLimit is applied to the two-element array built for colliding values.
Conflict containers retain a correct index and arrayLimit during strictMerge.
Nesting added by repeated strictMerge conflicts is bounded.
Merge overflow containers use their own keys to seed the index.
Inherited array format names are ignored.
With arrayFormat set to comma, elements without a callable toString no longer cause an exception.
In iso-8859-1 mode, + is encoded as %2B so values round-trip.
Structural separator dots are no longer re-encoded when encodeDotInKeys is set.
With arrayFormat set to comma, the full encoder arguments are passed when encodeValuesOnly is enabled.
Flattens a collection appended to an overflowed array.
Encodes dots in a top-level key with a primitive value when encodeDotInKeys is set.
Preserves surrogate-pair encoding across chunks.
Avoids invoking the __proto__ setter when copying own properties.
Enforces arrayLimit consistently across merge's array paths.
Uses the configured delimiter after charsetSentinel.
Skips null/undefined filter-array entries instead of crashing in the encoder.
Applies the formatter to the encoded key under strictNullHandling.
The duplicates option no longer applies to bracket notation keys.
arrayLimit means maximum count, not maximum index, in combine, merge, and parseArrayValue.
Ignore a key when a custom decoder returns null for it.
Fixes regressions from the robustness refactor.
Fixes a regression from the robustness refactor.