skillfed

emails

Modern python library for emails.

emails v1.1.2 796.0K downloads/30d#5,033 on PyPI425
Permissive license Apache License 2.0 Active released

What it is and what it does

python-emails is a high-level library for composing and sending emails in Python, sitting above the standard library's email and smtplib modules. It handles HTML and plain-text messages in a single object, manages attachments and inline images, supports template rendering, applies HTML transformations like CSS inlining, signs messages with DKIM, and sends via SMTP with TLS/SSL—all without requiring manual MIME tree construction.

The library is designed for developers who need more than basic plain-text SMTP but want to avoid boilerplate. It depends on python-dateutil for date handling, puremagic for file type detection, and dkimpy for cryptographic signing. The package is production-stable, actively maintained, and supports Python 3.10 through 3.14.

Use it for:

  • Send transactional emails (receipts, confirmations) with HTML formatting and PDF attachments
  • Render templated emails using Jinja2 or Mako with dynamic content and CSS inlining
  • Build marketing or notification emails with inline images and HTML transformations
  • Sign outgoing emails with DKIM for improved deliverability and authentication
  • Load and transform email messages from external sources (URLs, files, ZIP archives)
  • Integrate email sending into Django applications via the DjangoMessage class

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Build and send HTML and plain-text emails with attachments, inline images, template rendering, and DKIM signing through a high-level Python API.

Yes. The package is actively maintained, has no known vulnerabilities, low install friction, and a permissive license. Install it if you need to send HTML emails, attach files, render templates, or sign with DKIM—features that would otherwise require substantial boilerplate. Skip it only if you need only minimal plain-text SMTP and want to avoid any dependencies.

Install

emails on PyPI

pip

pip install emails

uv

uv add emails

poetry

poetry add emails

Installing emails

Before you install

Low install friction with a pure-Python wheel. Active maintenance with a recent release 88 days ago and ongoing commits. Depends on python-dateutil, puremagic, and dkimpy—all stable, widely-used libraries.

License in practice

Apache 2.0 permissive license allows commercial and private use with minimal restrictions, making it suitable for most projects.

Quickstart

pip install emails

import emails

message = emails.html(
    subject="Test",
    html="<p>Hello</p>",
    mail_from=("sender", "sender@example.com")
)
response = message.send(
    to="recipient@example.com",
    smtp={"host": "smtp.example.com", "port": 587, "tls": True}
)

Requires Python 3.10 or later. SMTP credentials and a working mail server are needed to send messages.

Verify before relying

  • Whether optional extras (html, jinja, async) are automatically installed or require explicit specification
  • Performance characteristics when handling large attachments or bulk message composition
  • Compatibility details with async/await patterns beyond the aiosmtplib integration mentioned

Package facts

License Apache License 2.0 (permissive)
Python support supports the current Python release (>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 3 — python-dateutil, puremagic, dkimpy
Maintenance actively maintained — 88 days since the last release
Last repo commit
First released
Downloads 796,004/month — #5,033 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: emails-1.1.2-py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseNatural Language :: EnglishOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: CommunicationsTopic :: Internet :: WWW/HTTPTopic :: Other/Nonlisted TopicTopic :: Software Development :: Libraries :: Python Modules

Tags

send emails pythonhtml email buildersmtp email libraryemail attachments inline imagesdkim email signingemail template renderingcompose emails python
email-deliverysmtp-clienthtml-email

More Python Modules packages