Repository navigation
Releases: fastapi/fastapi
Release list
0.162.0
Omitted bool and bool | None form fields now use their declared defaults or produce missing-field errors, consistent with other fields and Pydantic behavior. FastAPI no longer infers False for omitted booleans. This applies to individual form parameters, form models, and unions of form models.
Omitted boolean model fields are excluded from model_dump(exclude_unset=True), and their defaults no longer count as submitted fields during union selection. Default factories and validate_default follow the usual rules.
For HTML checkboxes, declare a boolean with a default of False. See Boolean Form Fields.
Breaking Changes
0.161.1
0.161.0
0.160.0
Query, header, cookie, and form parameter models now apply their extra configuration to all submitted fields in the same parameter location, consistent with Pydantic behavior. This includes fields declared in other models, individual parameters, or dependencies, which were previously excluded.
With extra="forbid", fields outside the model are rejected even if another parameter declares them. With extra="allow", those fields are included as model extras. With the default extra="ignore", they are ignored.
Breaking Changes
Internal
- ⬆ Bump certifi from 2026.1.4 to 2026.10.19. PR #16571 by @dependabot[bot].
