Framework Integration

Django + Unosend

Send transactional emails from your Django application using Unosend. Replace Django's default SMTP backend with the Unosend API for better deliverability and tracking.

Features

Everything you need to send emails from Django

Custom Django email backend

Works with Django templates

Celery async support

Django signals integration

Full Python type hints

Quick Start

Get up and running in minutes with this code example

Code Example
# views.py
import requests

UNOSEND_API_KEY = os.environ['UNOSEND_API_KEY']

def send_welcome_email(user):
    response = requests.post(
        'https://api.unosend.co/v1/emails',
        headers={
            'Authorization': f'Bearer {UNOSEND_API_KEY}',
            'Content-Type': 'application/json',
        },
        json={
            'from': 'welcome@yourdomain.com',
            'to': user.email,
            'subject': f'Welcome, {user.first_name}!',
            'html': render_to_string('emails/welcome.html', {'user': user}),
        }
    )
    return response.json()

Setup Guide

Follow these steps to integrate Unosend with Django

1

Install requests: pip install requests

2

Add UNOSEND_API_KEY to your environment variables

3

Create an email utility function or custom backend

4

Use Django templates for HTML email content

5

Call your send function from views or signals

Why Use Unosend with Django?

Better deliverability than SMTP

Email analytics and tracking

Works with existing Django templates

Easy migration from Django mail

Ready to integrate?

Start sending emails from Django in under 5 minutes. Free tier includes 5,000 emails/month.