Skip to main content

Flask-Mail

Flask-Mail is an extension for Flask that makes it easy to send emails from your application. It simplifies the process of integrating email functionality, allowing you to focus on building great features for your application.

Pallets Community Ecosystem

[!IMPORTANT]
This project is part of the Pallets Community Ecosystem. Pallets is the open source organization that maintains Flask; Pallets-Eco enables community maintenance of related projects. If you are interested in helping maintain this project, please reach out on the Pallets Discord server.

A Simple Example

from flask import Flask
from flask_mail import Mail, Message

app = Flask(__name__)
app.config['MAIL_SERVER'] = 'your_mail_server'
app.config['MAIL_PORT'] = 587
app.config['MAIL_USE_TLS'] = True
app.config['MAIL_USE_SSL'] = False
app.config['MAIL_USERNAME'] = 'your_username'
app.config['MAIL_PASSWORD'] = 'your_password'
app.config['MAIL_DEFAULT_SENDER'] = 'your_email@example.com'

mail = Mail(app)

@app.route('/')
def send_email():
  msg = Message(
    'Hello',
    recipients=['recipient@example.com'],
    body='This is a test email sent from Flask-Mail!'
  )
  mail.send(msg)
  return 'Email sent succesfully!'

Release files for Flask-Mail 0.10.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Flask-Mail 0.10.0
File Size Uploaded
flask_mail-0.10.0.tar.gz 8.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for Flask-Mail 0.10.0
File Interpreter ABI Platform
flask_mail-0.10.0-py3-none-any.whl Python 3 none any Details

Total release size: 16.7 kB

Release files / flask_mail-0.10.0.tar.gz

Download URL flask_mail-0.10.0.tar.gz
Size 8.2 kB
Tags Source
SHA-256 checksum
How to use checksums
44083e7b02bbcce792209c06252f8569dd5a325a7aaa76afe7330422bd97881d
BLAKE2b-256 checksum
How to use checksums
ba29e92dc84c675d1e8d260d5768eb3fb65c70cbd33addecf424187587bee862
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/5.0.0 CPython/3.12.3

Release files / flask_mail-0.10.0-py3-none-any.whl

Download URL flask_mail-0.10.0-py3-none-any.whl
Size 8.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a451e490931bb3441d9b11ebab6812a16bfa81855792ae1bf9c1e1e22c4e51e7
BLAKE2b-256 checksum
How to use checksums
e4c0a81083da779f482494d49195d8b6c9fde21072558253e4a9fb2ec969c3c1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/5.0.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

0.10.0 This release

2 release files

0.9.1

1 release file

0.9.0

1 release file

0.8.2

1 release file

0.8.1

1 release file

0.8.0

1 release file

0.7.6

1 release file

0.7.5

1 release file

0.7.4

1 release file

0.7.3

1 release file

0.7.2

1 release file

0.7.1

1 release file

0.7.0

1 release file

0.6.1

1 release file

0.6

2 release files

0.5.1

1 release file

0.5

1 release file

0.4

1 release file

0.3.5

1 release file

0.3.4

1 release file

0.3.3

1 release file

0.3.2

0.3.1

1 release file

0.3

1 release file

0.2.1

1 release file

0.2

1 release file

0.1.2

1 release file

0.1.1

1 release file

0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page