Skip to main content

Form validation and rendering for Python web development.

Project description

WTForms is a flexible forms validation and rendering library for Python web development. It can work with whatever web framework and template engine you choose. It supports data validation, CSRF protection, internationalization (I18N), and more. There are various community libraries that provide closer integration with popular frameworks.

Installation

Install and update using pip:

pip install -U WTForms

Third-Party Library Integrations

WTForms is designed to work with any web framework and template engine. There are a number of community-provided libraries that make integrating with frameworks even better.

  • Flask-WTF integrates with the Flask framework. It can automatically load data from the request, uses Flask-Babel to translate based on user-selected locale, provides full-application CSRF, and more.

  • WTForms-Alchemy provides rich support for generating forms from SQLAlchemy models, including an expanded set of fields and validators.

  • WTForms-SQLAlchemy provides ORM-backed fields and form generation from SQLAlchemy models.

  • WTForms-AppEngine provides ORM-backed fields and form generation from AppEnding db/ndb schema

  • WTForms-Django provides ORM-backed fields and form generation from Django models, as well as integration with Django’s I18N support.

  • WTForms-Bootstrap5 provides Bootstrap 5 favor renderer with great customizability.

  • Starlette-WTF integrates with Starlette and the FastAPI framework, based on the features of Flask-WTF.

  • Bootstrap-Flask Bootstrap-Flask is a collection of Jinja macros for Bootstrap 4 & 5 and Flask using Flask-WTF.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wtforms-3.1.2.tar.gz (134.7 kB view hashes)

Uploaded source

Built Distribution

wtforms-3.1.2-py3-none-any.whl (146.0 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page