finds.dev← search

// the find

miguelgrinberg/Flask-Migrate

★ 2,407 · Python · MIT · updated May 2026

SQLAlchemy database migrations for Flask applications using Alembic

Flask-Migrate wraps Alembic to give Flask apps a `flask db` command set for managing SQLAlchemy migrations. It's the de facto standard for this — if you're using Flask + SQLAlchemy and not Alembic directly, this is what you reach for. Maintainer is Miguel Grinberg, so it's well-maintained and not going anywhere.

The integration is tight — Migrate(app, db) and you're done, with the app's config automatically wired into Alembic's env.py. Multi-DB support is built in via a separate template, which is genuinely useful and often an afterthought in wrappers like this. The async (aioflask) template support is included, not bolted on later. Miguel keeps this maintained against current Flask/SQLAlchemy versions, which is not a given for ecosystem glue packages.

This is a thin wrapper, and Alembic's rough edges come straight through — auto-generated migrations still miss indexes, certain column type changes, and anything involving constraints, so every `flask db migrate` output needs a human review before running. There's no built-in way to test migrations against a real schema before applying them; you find out migrations are wrong in staging. The CLI doesn't expose Alembic's full surface area, so if you need something slightly off the happy path (e.g., offline migrations, custom revision environments) you end up editing the generated env.py directly and working around the wrapper.

View on GitHub →

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →