---
"@context": https://schema.org
"@type": TechArticle
"@id": https://www.twilio.com/docs/email/api/mail-send#article
headline: Mail Send
description: |
  Send emails with the Twilio Email API. See cURL examples for single and multiple recipients, Liquid personalization, scheduled sends, custom headers, and tags.
url: https://www.twilio.com/docs/email/api/mail-send
inLanguage: en
dateModified: 2026-08-20T18:09:16.000Z
author:
  "@type": Organization
  name: Twilio Developer Education Team
publisher:
  "@type": Organization
  name: Twilio
---

# Mail Send

Send emails to one or more recipients. The API processes requests asynchronously and returns a `202` response that includes an `operationId` you can use to track send status.

## Send to a single recipient

To send an email to one recipient, include a single object in the `to` array:

```bash {title="Send an email to a single recipient"}
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "support@example.com",
        "name": "Support Team"
    },
    "to": [
        {
            "address": "john.doe@example.com",
            "name": "John Doe"
        }
    ],
    "content": {
        "subject": "Your subject line",
        "html": "<p>Your message content in HTML format.</p>",
        "text": "Your message content in plain text."
    }
}' \
-u $TWILIO_API_KEY:$TWILIO_API_SECRET
```

**Response (202 Accepted)**:

```json
{
    "operationId": "comms_operation_01h9krwprkeee8fzqspvwy6nq8",
    "operationLocation": "https://comms.twilio.com/v1/Emails/Operations/comms_operation_01h9krwprkeee8fzqspvwy6nq8"
}
```

## Send to multiple recipients

To send the same email to multiple recipients, add an object for each recipient to the `to` array:

```bash {title="Send an email to multiple recipients"}
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "support@example.com",
        "name": "Support Team"
    },
    "to": [
        {
            "address": "john.doe@example.com",
            "name": "John Doe"
        },
        {
            "address": "jane.smith@example.com",
            "name": "Jane Smith"
        }
    ],
    "content": {
        "subject": "Your subject line",
        "html": "<p>Your message content in HTML format.</p>",
        "text": "Your message content in plain text."
    }
}' \
-u $TWILIO_API_KEY:$TWILIO_API_SECRET
```

## Personalization with variables

Use Liquid templating to personalize emails for each recipient:

```bash {title="Personalize an email with Liquid variables"}
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "support@example.com",
        "name": "Support Team"
    },
    "to": [
        {
            "address": "jane.doe@example.com",
            "variables": {
                "firstName": "Jane",
                "lastName": "Doe"
            }
        },
        {
            "address": "john.doe@example.com",
            "variables": {
                "firstName": "John",
                "lastName": "Doe"
            }
        }
    ],
    "content": {
        "subject": "Hello {{ firstName }}",
        "html": "<html><body>Hey {{ firstName | default: '\''there'\'' }} {{ lastName }}, your order is ready.</body></html>",
        "text": "Hey {{ firstName | default: '\''there'\'' }} {{ lastName }}, your order is ready."
    }
}' \
-u $TWILIO_API_KEY:$TWILIO_API_SECRET
```

## Schedule an email

Schedule an email to be sent at a future time. Provide a `sendAt` value in [RFC 3339](https://www.rfc-editor.org/rfc/rfc3339) format. You can schedule emails up to 7 days in advance.

```bash {title="Schedule an email for a future send time"}
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "support@example.com",
        "name": "Support Team"
    },
    "to": [
        {
            "address": "john.doe@example.com",
            "name": "John Doe"
        }
    ],
    "content": {
        "subject": "Scheduled Reminder",
        "html": "<html><body>This is your scheduled reminder.</body></html>"
    },
    "schedule": {
        "sendAt": ["2026-12-15T14:15:22Z"]
    }
}' \
-u $TWILIO_API_KEY:$TWILIO_API_SECRET
```

## Custom headers

Add custom headers to your emails for tracking and categorization:

```bash {title="Add custom headers to an email"}
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "marketing@example.com",
        "name": "Marketing Team"
    },
    "to": [
        {
            "address": "customer@example.com",
            "name": "Customer"
        }
    ],
    "content": {
        "subject": "Special Offer",
        "html": "<html><body><h1>Exclusive Deal!</h1></body></html>",
        "text": "Exclusive Deal!",
        "headers": {
            "X-Campaign-ID": "CAMPAIGN-2026-Q1",
            "X-Customer-Segment": "premium",
            "X-Priority": "high"
        }
    }
}' \
-u $TWILIO_API_KEY:$TWILIO_API_SECRET
```

**Note**: You can't override these headers: `x-sg-id`, `x-sg-eid`, `received`, `dkim-signature`, `Content-Type`, `Content-Transfer-Encoding`, `To`, `From`, `Subject`, `Reply-To`, `CC`, `BCC`.

## Tags for tracking

Add custom metadata tags to emails for filtering and tracking:

```bash {title="Add tags to an email"}
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "newsletter@example.com",
        "name": "Newsletter Team"
    },
    "to": [
        {
            "address": "john.doe@example.com",
            "name": "John Doe"
        }
    ],
    "content": {
        "subject": "January Newsletter",
        "html": "<html><body><h1>Newsletter</h1></body></html>"
    },
    "tags": {
        "campaign": "monthlyNewsletter",
        "edition": "january_2026"
    }
}' \
-u $TWILIO_API_KEY:$TWILIO_API_SECRET
```

For more details on tag constraints, see [Tags](/docs/email/api/overview#tags).
