Skip to main content
The Flask ecosystem includes many high-quality extensions that add functionality to your applications. This page provides a curated list of popular and well-maintained extensions for common use cases.

Finding Extensions

You can search PyPI for packages tagged with Framework :: Flask to discover more extensions beyond this list.

Database Extensions

Flask-SQLAlchemy

Flask-SQLAlchemy is an extension for Flask that adds support for SQLAlchemy to your application. It provides a high-level ORM for working with relational databases.

Flask-Migrate

Flask-Migrate is an extension that handles SQLAlchemy database migrations for Flask applications using Alembic. It allows you to version and manage your database schema changes.
  • Install: flask-migrate
  • Import: flask_migrate
  • Use Case: Database migrations and schema versioning
  • Works With: Flask-SQLAlchemy

Flask-MongoEngine

Flask-MongoEngine provides integration with MongoEngine, an Object-Document Mapper (ODM) for working with MongoDB from Python.
  • Install: flask-mongoengine
  • Import: flask_mongoengine
  • Use Case: MongoDB integration with ODM support

Authentication & Authorization

Flask-Login

Flask-Login provides user session management for Flask. It handles the common tasks of logging in, logging out, and remembering users’ sessions over extended periods of time.
  • Install: flask-login
  • Import: flask_login
  • Use Case: User session management and authentication
  • Documentation: flask-login.readthedocs.io

Flask-Principal

Flask-Principal provides identity and permission management for Flask applications. It allows you to define roles and permissions for users.
  • Install: flask-principal
  • Import: flask_principal
  • Use Case: Role-based access control and permissions

Flask-JWT-Extended

Flask-JWT-Extended adds support for using JSON Web Tokens (JWT) to Flask for protecting routes and handling authentication in APIs.
  • Install: flask-jwt-extended
  • Import: flask_jwt_extended
  • Use Case: JWT authentication for APIs

Forms & Validation

Flask-WTF

Flask-WTF integrates Flask with WTForms, providing simple integration with form rendering, validation, and CSRF protection.
  • Install: flask-wtf
  • Import: flask_wtf
  • Use Case: Form handling, validation, and CSRF protection
  • Documentation: flask-wtf.readthedocs.io

API Development

Flask-RESTful

Flask-RESTful is an extension for Flask that adds support for quickly building REST APIs. It encourages best practices with minimal setup.
  • Install: flask-restful
  • Import: flask_restful
  • Use Case: Building RESTful APIs

Flask-CORS

Flask-CORS is a Flask extension for handling Cross Origin Resource Sharing (CORS), making cross-origin AJAX possible.
  • Install: flask-cors
  • Import: flask_cors
  • Use Case: Handling CORS headers for API endpoints

Flask-Marshmallow

Flask-Marshmallow is a thin integration layer for Flask and marshmallow (an object serialization/deserialization library) that adds additional features to marshmallow.
  • Install: flask-marshmallow
  • Import: flask_marshmallow
  • Use Case: Object serialization and deserialization for APIs

Admin Interfaces

Flask-Admin

Flask-Admin is a simple and extensible administrative interface framework for Flask. It allows you to quickly build admin panels for your models.
  • Install: flask-admin
  • Import: flask_admin
  • Use Case: Building admin interfaces for database models
  • Documentation: flask-admin.readthedocs.io

Email

Flask-Mail

Flask-Mail provides a simple interface to set up SMTP with your Flask application and to send messages from your views and scripts.
  • Install: flask-mail
  • Import: flask_mail
  • Use Case: Sending emails from Flask applications

Caching

Flask-Caching

Flask-Caching adds easy cache support to Flask applications. It supports various backends including Redis, Memcached, and simple in-memory caching.
  • Install: flask-caching
  • Import: flask_caching
  • Use Case: Caching responses and data to improve performance

Task Queues

Flask-RQ

Flask-RQ adds RQ (Redis Queue) support to Flask. It allows you to run background jobs and tasks asynchronously.
  • Install: flask-rq2
  • Import: flask_rq2
  • Use Case: Background job processing with Redis

Celery

While not Flask-specific, Celery is commonly used with Flask for handling asynchronous tasks and scheduled jobs.
  • Install: celery
  • Import: celery
  • Use Case: Distributed task queue for asynchronous processing
  • Documentation: docs.celeryq.dev

Static Assets

Flask-Assets

Flask-Assets helps you to integrate webassets into your Flask application. It allows you to manage CSS and JavaScript assets, including minification and bundling.
  • Install: flask-assets
  • Import: flask_assets
  • Use Case: Managing and bundling static assets

Internationalization

Flask-Babel

Flask-Babel adds i18n and l10n support to Flask applications with the help of babel and pytz. It allows you to create multilingual applications.
  • Install: flask-babel
  • Import: flask_babel
  • Use Case: Internationalization and localization

Testing

Flask-Testing

Flask-Testing provides unit testing utilities for Flask applications.
  • Install: flask-testing
  • Import: flask_testing
  • Use Case: Unit testing utilities and helpers

Session Management

Flask-Session

Flask-Session is an extension that adds support for server-side sessions to your application. It allows you to store session data on the server instead of in cookies.
  • Install: flask-session
  • Import: flask_session
  • Use Case: Server-side session storage (Redis, Memcached, etc.)

Security

Flask-Talisman

Flask-Talisman is a small extension that handles setting HTTP headers that can help protect against a few common web application security issues.
  • Install: flask-talisman
  • Import: flask_talisman
  • Use Case: Security headers (HTTPS, CSP, HSTS, etc.)

Flask-Limiter

Flask-Limiter provides rate limiting for Flask routes. It helps protect your application from abuse and DoS attacks.
  • Install: flask-limiter
  • Import: flask_limiter
  • Use Case: Rate limiting and throttling

Development & Debugging

Flask-DebugToolbar

Flask-DebugToolbar is a port of the Django debug toolbar to Flask. It adds a toolbar overlay with debugging information when your application is in debug mode.
  • Install: flask-debugtoolbar
  • Import: flask_debugtoolbar
  • Use Case: Development debugging and profiling

Community Maintenance

Many Flask extensions are maintained by the community under the Pallets-Eco organization on GitHub. This organization allows for community maintenance with oversight from the Pallets maintainers, ensuring extensions remain compatible with current Flask versions.

Creating Your Own Extension

If you don’t find an extension that fits your needs, you can create your own. See the Extension Development guide to learn how to develop and publish your own Flask extension.

Build docs developers (and LLMs) love