flask tutorial by Corey Schafer To create a db: open the python env and type from app import db db.create_all()