Database migration with Flask, SQLAlchemy and Alembic
A concise guide exploring why database migration matters in Flask applications, highlighting SQLAlchemy models, Alembic migrations, and the…
Database migration with Flask, SQLAlchemy and Alembic
A concise guide exploring why database migration matters in Flask applications, highlighting SQLAlchemy models, Alembic migrations, and the orchestration between them.

Photo by Ernesto RƎIƎZ.
Database migrations are essential for keeping evolving applications aligned with changing data models, without losing consistency or integrity.
In this article, we’ll examine how Flask, SQLAlchemy, and Alembic work together to manage schema changes while ensuring smooth upgrades to your database schema.
⬇️⬇️⬇️ Read the full article
To follow me
Thanks for reading this article. Make sure to follow me on X, subscribe to my Substack publication and bookmark my blog to read more in the future.
Why does this post link to my blog?
I have been on Medium for a while and, frankly, the editor isn’t the best:
- when I copy paste a post content from my blog on Medium, all the code extracts need manual adjustments.
- Medium doesn’t support WEBP or AVIF…
- Setting the alternative text on an image bumps the focus back to the top… Not great for a long post!
Moreover, my analytics shows that very little traffic to my blog comes from Medium.
메타데이터
- post_id
- a69e7cdc6113
- slug
- database-migration-with-flask-sqlalchemy-and-alembic-a69e7cdc6113
- url
- https://medium.com/@jeremie-litzler/database-migration-with-flask-sqlalchemy-and-alembic-a69e7cdc6113
- canonical_url
- https://medium.com/@jeremie-litzler/database-migration-with-flask-sqlalchemy-and-alembic-a69e7cdc6113
- author_url
- https://medium.com/@jeremie-litzler
- status
- ok
- fetched_at
- 2026-06-09 15:37:30