dacite
Simple creation of data classes from dictionaries.
Install
dacite on PyPI
pip
pip install daciteuv
uv add dacitepoetry
poetry add dacitePackage facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.7) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — dataclasses |
| Maintenance | aging — 554 days since the last release |
| Last repo commit | |
| First released | |
| Popularity | one of the top 1,000 most-downloaded packages on PyPI (30-day window, as of 2026-08-13) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-13) |
Evidence: dacite-1.9.2-py3-none-any.whl
Keywords: dataclasses
About dacite
from the package's own PyPI description — quoted content, verbatim
dacite
Build Status (image) Coverage Status (image) License (image) Version (image) Python versions (image) Code style: black (image)
This module simplifies creation of data classes ([PEP 557][pep-557]) from dictionaries.
Installation
To install dacite, simply use pip:
$ pip install dacite
Requirements
Minimum Python version supported by dacite is 3.7.
Quick start
```python from dataclasses import dataclass from dacite import from_dict
@dataclass class User: name: str age: int...
Read as markdown · JSON record · Source repository · Homepage
AI interpretation — verify before relying
AI-generated interpretation of the package facts above; every digit, version, license, or vulnerability id it cites is grounded in the facts already shown on this page
Dacite converts dictionaries into instances of Python dataclasses, handling nested structures, type checking, optional fields, unions, generics, and collections with minimal boilerplate.
Low friction: pure Python wheel with only the standard library's dataclasses as a runtime dependency. Last release was 554 days ago; the repository remains active with a recent commit on 2025-03-17, though the aging maintenance status suggests infrequent updates.
MIT license (permissive) places no restrictions on use, modification, or redistribution in proprietary or open-source projects.
Usage
pip install dacite==1.9.2
from dataclasses import dataclass
from dacite import from_dict
@dataclass
class User:
name: str
age: int
user = from_dict(User, {'name': 'John', 'age': 30})
Requires Python 3.7 or later; dataclasses module is built-in from Python 3.7 onward.
Verdict: Dacite is a stable, lightweight utility for converting dictionaries to typed dataclass instances. With zero known vulnerabilities, minimal dependencies, and broad Python version support (3.7–3.13), it is well-suited for projects needing simple dict-to-dataclass conversion without the overhead of a full validation framework. The aging maintenance status and 554-day gap since the last release suggest it is mature but not actively developed.
Needs verification
- Whether the package is suitable for high-frequency deserialization or if performance characteristics matter for your use case.
- Whether custom type hooks and casting features are sufficient for your specific data transformation needs.
Similar packages
permissive · top 1,000 on PyPI
typedloadcopyleft · top 1,000 on PyPI
typing-inspectpermissive · top 1,000 on PyPI
jiterpermissive · top 1,000 on PyPI
nexus-rpcpermissive · top 1,000 on PyPI
mashumaropermissive · top 1,000 on PyPI
cycloptspermissive · top 1,000 on PyPI
cattrspermissive · top 1,000 on PyPI
factory-boypermissive · top 1,000 on PyPI
pyrsistentpermissive · top 1,000 on PyPI