Skip to main content
Help the Python Software Foundation raise $60,000 USD by December 31st!  Building the PSF Q4 Fundraiser

A super simple CLI for sending emails

Project description

Netlify Status MIT license Coverage Status Build Status GitSpo Mentions


A super simple CLI for sending emails


Maildown is a command line interface that lets you send emails with a minimum of fuss. It currently supports the AWS SES (default) and Sendgrid as email backends. Support for more email providers will be added in the future

Why can't I just use boto3/the SendGrid API?

Maildown makes it easier to add structure and style to your email content. It supports Markdown syntax out of the box, meaning that you can just send Markdown files as emails with no additional effort.

How much does it cost?

Maildown is open source and therefore completely free. However, it relies on third party services (e.g. AWS, SendGrid) to actually send your emails - these services aren't free, alhough they do have free limits depending on the number of emails you need to send

Installation and usage

Pre requisites

In order to use Maildown, you first need to create an account with one of the supported backend email providers:

Install with pip

You can install maildown as follows:

pip install maildown

Authenticating Maildown

Maildown stores your credentials locally for convenience. Before you can use Maildown's features, you should run the maildown init command. By default, maildown uses the AWS backend:

maildown init access_key=AWS_ACCESS_KEY_ID secret_key=AWS_SECRET_ACCESS_KEY

To use the SendGrid API, you'll need to pass the --backend=sendgrid option with all commands:

maildown init api_key=SENDGRID_API_KEY --backend=sendgrid

If you have previously used the aws cli and have already run aws configure, or if you have set the environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY in your environment, you can just use maildown init with no arguments to store your credentials

Verify email addresses

Amazon only lets you send emails from verified email addresses - In other words, you need to verify that you own your email address before you can send mails from it. You can either do this from the SES console, or by using Maildown:

$ maildown verify
Email sent to You must click the link in this email to verify ownership before you can send any emails

When you use the above command, AWS will send an email to the email address you provided. You'll need to click on the link to verify your ownership of the account. Once you've done this, you can repeat the previous command to check the status

$ maildown verify
This email address has already been verified

You are now ready to start sending emails!

.. note: This command is AWS-specific - The SendGrid backend does not implement this feature

Sending emails

You can now send emails with the following command

maildown send "my email subject" -f ""

The above arguments, in order, are:

  • The sending email address (which must have been verified)
  • The subject line of your email
  • A markdown file containing some content to send. Note that you can also use the -c flag to pass string content to be sent directly to the email, e.g. -c "hello"
  • A list of email addresses to send the content to

Styling emails

By default, Maildown bakes in its own default style sheet when sending emails. This looks something like this (the below email is the content of this readme):


You can apply your own styles by simply using the --theme flag when sending mails, like this:

maildown send "my email subject" -f "" --theme "my-style.css"

Project details

Download files

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

Files for maildown, version 1.2.0
Filename, size File type Python version Upload date Hashes
Filename, size maildown-1.2.0-py3-none-any.whl (13.3 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size maildown-1.2.0.tar.gz (12.1 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page