You can use the ilike() function to perform a case-insensitive query in Flask-Sqlalchemy. For example, if you want to search for all records that contain the word apple, regardless of case, you could use the following code: result = MyModel.query.filter(MyModel.name.ilike('%apple%')).all()