# benavlabs/FastAPI-boilerplate

An extendable async API using FastAPI, Pydantic V2, SQLAlchemy 2.0, PostgreSQL and Redis.

Repository: https://github.com/benavlabs/FastAPI-boilerplate
Canonical: https://ross.abutalabs.com/products/fastapi-boilerplate
Homepage: https://benavlabs.github.io/FastAPI-boilerplate/
Language: Python
License: MIT
License Family: permissive
Topics: alembic, api, async, docker, fastapi, fastapi-boilerplate, postgres, pydantic-v2, python, sqlalchemy, uvicorn, cache, redis, arq, docker-compose
Last push: 2026-08-08T05:07:09+00:00

## Health v2 (maintenance only)
Score: 86/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 96, release rhythm 78, longevity 76
- inputs: {"age_days": 1077, "days_push": 25, "days_rel": 70, "gap_med": 32, "n_releases_24m": 6}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2064, forks 306 (observed 2026-08-28T04:06:09.966243+00:00)

## What it is
Fastro is a production-ready FastAPI boilerplate providing an async API foundation with FastAPI, Pydantic V2, SQLAlchemy 2.0, PostgreSQL, and Redis. It ships with authentication, CRUD, background jobs, caching, rate limiting, Alembic migrations, Docker Compose setups, and a plugin-aware CLI for code generation.

## Use cases
- start a new async FastAPI API project
- bootstrap a SaaS backend with auth and CRUD
- set up FastAPI with PostgreSQL, Redis, and Docker Compose
- add background task workers and caching to a Python API
- get session auth, OAuth, and API keys out of the box
- generate production Docker Compose configs for FastAPI
- scaffold a rate-limited API with role-based access control

## When to choose
- starting a new Python async API or SaaS from scratch
- you want batteries-included auth, CRUD, caching, and jobs with sensible defaults
- you prefer FastAPI with SQLAlchemy 2.0 and Pydantic V2
- you want Docker Compose-based local and production setups

## When to avoid
- you use Django, Flask, or a non-Python stack
- you need a minimal template without opinionated infrastructure
- your project requires a database other than PostgreSQL
- you want a fully managed backend rather than self-hosted code

## Facets
- artifact type: learning-resource
- maturity: active
- function: web-framework, auth, orm, caching, rate-limiting, api-framework, cli, middleware, routing
- domain: web-development, backend, apis, developer-tools, self-hosted
- platform: python, self-hosted
- tags: fastapi, pydantic-v2, sqlalchemy, postgresql, redis, taskiq, alembic, starter-template, async, crud, saas-starter, boilerplate, docker, web-server

## Member repositories
- benavlabs/FastAPI-boilerplate (main) score 86

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:09.966243+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T08:32:00.198728+00:00, confidence not recorded.
  - readme: https://github.com/benavlabs/FastAPI-boilerplate (fetched 2026-08-28T04:06:09.966243+00:00, sha 57315b6e78ae)
  - homepage: https://benavlabs.github.io/FastAPI-boilerplate/ (fetched 2026-08-29T10:37:19.247827+00:00, sha 9690ac47e077)
- Data as of 2026-08-30T08:39:29.467469+00:00.
