Email domains allow you to send emails from your own domain (e.g., `newsletter@yourdomain.com`) instead of a shared domain. This improves deliverability, builds trust, and strengthens your brand.

## Why Use a Custom Email Domain?

- **Better Deliverability**: Emails from your own domain are less likely to be marked as spam
- **Brand Recognition**: Recipients see your domain, not a generic one
- **Professional Appearance**: Build trust with a consistent brand experience
- **Domain Reputation**: Build your own sender reputation over time

## Adding an Email Domain

1. Go to **Domains** in your organization settings
2. Click **Add Email Domain**
3. Enter your domain name (e.g., `yourdomain.com`)
4. Click **Create**

Each plan includes a fixed number of sending domains: **1 on Free, 10 on Creator, 50 on Pro, 1,000 on Business**. Shared test domains do not count. When you hit the cap, **Upgrade** opens the billing plan page.

## DNS Configuration

After adding your domain, you'll need to configure DNS records at your domain registrar. Lumail.io requires the following records:

### SPF Record

SPF (Sender Policy Framework) authorizes Lumail.io to send emails on behalf of your domain.

| Type | Host | Value                               |
| ---- | ---- | ----------------------------------- |
| TXT  | @    | `v=spf1 include:amazonses.com ~all` |

### DKIM Records

DKIM (DomainKeys Identified Mail) signs your emails to verify they haven't been tampered with.

You'll receive 3 CNAME records to add:

| Type  | Host                | Value                         |
| ----- | ------------------- | ----------------------------- |
| CNAME | `[key1]._domainkey` | `[value1].dkim.amazonses.com` |
| CNAME | `[key2]._domainkey` | `[value2].dkim.amazonses.com` |
| CNAME | `[key3]._domainkey` | `[value3].dkim.amazonses.com` |

### DMARC Record (Recommended)

DMARC tells receiving servers what to do with emails that fail SPF or DKIM checks. Start with `p=none` (monitor only), then move to `p=quarantine` or `p=reject`. Lumail warns while the policy stays on `p=none`.

| Type | Host     | Value                                               |
| ---- | -------- | --------------------------------------------------- |
| TXT  | `_dmarc` | `v=DMARC1; p=none; rua=mailto:dmarc@yourdomain.com` |

If the sending domain is a subdomain and `_dmarc` is only on the root, edit the **root** record. See [How to add DMARC](/docs/deliverability/how-to-add-dmarc) and [How to strengthen DMARC](/docs/deliverability/how-to-strengthen-dmarc).

## Verification

After adding DNS records:

1. Return to the domain detail page
2. Click **Check Verification Status**
3. Wait for DNS propagation (can take up to 48 hours)

Once verified, the domain status will change from **Pending** to **Verified**.

## Fallback Domains

Fallback domains keep campaign and workflow emails moving when the primary sending domain has a domain-level SES issue, such as an invalid MAIL FROM setup or a rejected sender identity.

On the **Domains** page, use the **Fallback** column to assign a verified email domain to a priority:

- **Priority 1** is tried first
- **Priority 2** is tried after Priority 1
- **Priority 3** is tried last
- **Off** means the domain is not used as a fallback

When a primary domain fails, Lumail.io tries fallback domains in priority order. If a fallback succeeds, Lumail.io caches that fallback choice for 10 minutes for the same organization and primary domain. During that window, new emails skip the failing primary domain and use the cached fallback directly.

The fallback keeps the same display name and local part, but replaces the domain. For example, `Melvyn <hello@primary.com>` can be retried as `Melvyn <hello@fallback.com>`.

Admins receive a notification when a fallback is used. If no fallback succeeds, Lumail.io sends an urgent failure notification and stops retrying permanent SES failures for that recipient.

Fallback domains only help with domain or identity failures. They do not fix account-level quota limits, throttling, or a missing SES configuration set.

## Troubleshooting

### Domain stuck on "Pending"

- **DNS Propagation**: DNS changes can take up to 48 hours to propagate globally
- **Check Records**: Use a tool like [MXToolbox](https://mxtoolbox.com/) to verify your DNS records
- **TTL Settings**: Lower TTL values speed up propagation

### Emails going to spam

- Ensure all DNS records (SPF, DKIM, DMARC) are properly configured
- Start with a small sending volume and gradually increase
- Maintain good list hygiene (remove bounces and unsubscribes)

## Related Documentation

- [Send Email API](/docs/api-reference/api-emails-send) - Requires verified domain for `from` address
- [Deliverability Score](/docs/features/deliverability-score) - Monitor sender reputation
- [Content Deliverability](/docs/features/content-deliverability) - Optimize emails for inbox placement
