multidict
multidict implementation
Decision gist · record as of 2026-08-14
Yes. Multidict is a mature, actively maintained library in the top 100 PyPI packages with no known vulnerabilities. It solves a real problem—multi-value keys—that standard dicts cannot handle. Install friction is low, the license is permissive, and it has minimal dependencies. Use it whenever you work with HTTP headers, query strings, or any domain requiring multiple values per key.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.9 or later.
- C extensions require a C compiler and Python headers if building from source; use MULTIDICT_NO_EXTENSIONS=1 to skip compilation.
- Low install friction with a pure Python wheel available; active maintenance with recent commits.
License · maintenance · safety
Apache License 2.0 (permissive) — Licensed under Apache License 2.0 (permissive), allowing use in most commercial and open-source projects with minimal restrictions.
last release 2026-01-26 (200 days) · last repo commit 2026-08-13 · 491 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 594,005,645 downloads/mo, #59 on PyPI
Alternatives
Verify before relying
pip install multidict
from multidict import MultiDict
md = MultiDict([('key', 'val1'), ('key', 'val2')])
print(md.getall('key')) # ['val1', 'val2']- Performance characteristics of the pure Python version in production workloads beyond the stated 20-50x slowdown claim.
- Whether case-insensitive mode (CIMultiDict) is commonly used or primarily for edge cases.
What it is and what it does
Multidict is a specialized dictionary implementation that stores multiple values under the same key while maintaining insertion order. It's built for scenarios where standard Python dicts are insufficient—specifically HTTP headers and URL query parameters, where a single key can legitimately have multiple values. The package provides four classes: mutable MultiDict and CIMultiDict (case-insensitive), plus immutable proxy versions that provide dynamic views of the underlying collection.
The library ships with optional C extensions for performance; the pure Python fallback is available but significantly slower. It depends only on typing-extensions and has minimal install friction, with wheels available for common platforms. The package is actively maintained, production-stable, and widely used in web frameworks and HTTP clients.
Use it for
- Parse HTTP headers where a single header name can appear multiple times in a request or response.
- Handle URL query strings with repeated parameter names, preserving all values and order.
- Build case-insensitive header lookups in HTTP processing without manual normalization.
- Implement proxy views over mutable multidict collections that reflect underlying changes dynamically.
- Replace regular dicts in web frameworks and HTTP libraries that need multi-value semantics.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Multidict is a mature, actively maintained library in the top 100 PyPI packages with no known vulnerabilities. It solves a real problem—multi-value keys—that standard dicts cannot handle. Install friction is low, the license is permissive, and it has minimal dependencies. Use it whenever you work with HTTP headers, query strings, or any domain requiring multiple values per key.
Install
multidict on PyPI
Before you install
Low install friction with a pure Python wheel available; active maintenance with recent commits. Optional C extensions are available for performance but not required—the pure Python version is available via the MULTIDICT_NO_EXTENSIONS environment variable.
Requires Python 3.9 or later. C extensions require a C compiler and Python headers if building from source; use MULTIDICT_NO_EXTENSIONS=1 to skip compilation.
License in practice
Licensed under Apache License 2.0 (permissive), allowing use in most commercial and open-source projects with minimal restrictions.
Quickstart
pip install multidict
from multidict import MultiDict
md = MultiDict([('key', 'val1'), ('key', 'val2')])
print(md.getall('key')) # ['val1', 'val2']
Verify before relying
- Performance characteristics of the pure Python version in production workloads beyond the stated 20-50x slowdown claim.
- Whether case-insensitive mode (CIMultiDict) is commonly used or primarily for edge cases.
Package facts
| License | Apache License 2.0 permissive |
| Python support | Supports the current Python release >=3.9 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 1 packagetyping-extensions |
| Maintenance | Actively maintained 200 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 594,005,645 / month, #59 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.9 |
Evidence: multidict-6.7.1-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “http headers data structure”
- multidictMultidict is a dict-like container that allows multiple values per…
- http-sfvParses and serializes HTTP Structured Field Values according to the…
- jusTextjusText removes boilerplate content (navigation, headers, footers)…
Give your agent the search over MCP, or paste the wish link into any chat.
Similar packages
A case-insensitive ordered dictionary that preserves the original lexical case of its keys, supporting the full dict API with customizable casefolding.
orderedmultidict provides a dictionary that stores multiple values per key while preserving insertion order, with an API compatible with Python's built-in dict.
Provides an OrderedDict implementation for Python 2.4–2.6, preserving insertion order in a dictionary-like object with O(1) amortized insertion, deletion, and lookup performance.
A dict subclass that automatically omits None values when storing or serializing, and is both picklable and JSON-serializable.
Provides specialized sorted collection data structures (dictionaries, sets, lists) that maintain order and support efficient indexed access and value-based sorting, built on top of sortedcontainers.
Converts nested JSON objects into flat key-value dictionaries and back, preserving types using suffix notation, useful for HTML forms or query string parameters.
However, the aging maintenance status (706 days since last release) means you should verify it handles your specific JSON structures before relying on it in…
See also flatten-dict · orderly-set · query-string · pylru