Quickstart: How to add custom verified email domains

In this quick start, you learn how to provision a custom verified email domain in Azure Communication Services.

Prerequisites

Azure Managed Domains compared to Custom Domains

Before provisioning a custom email domain, review the following table to decide which domain type best meets your needs.

Azure Managed Domains Custom Domains
Pros: - Setup is quick & easy
- No domain verification required
- Emails are sent from your own domain
Cons: - Sender domain isn't personalized and can't be changed
- Sender usernames can't be personalized
- Limited sending volume
- User Engagement Tracking can't be enabled
- Requires verification of domain records
- Longer setup for verification

Provision a custom domain

To provision a custom domain, you need to:

  • Verify the custom domain ownership by adding a TXT record in your Domain Name System (DNS).
  • Configure the sender authentication by adding Sender Policy Framework (SPF) and DomainKeys Identified Mail (DKIM) records.

Verify custom domain

In this section, you verify the custom domain ownership by adding a TXT record in your DNS.

  1. Open the Overview page of the Email Communication Service resource that you created in Get started with Creating Email Communication Resource.

  2. Create a custom domain using one of the following options.

    • (Option 1) Click the Setup button under Setup a custom domain. Continue to step 3.

      Screenshot that shows how to set up a custom domain.

    • (Option 2) Click Provision Domains on the left navigation panel.

      Screenshot that shows the navigation link to Provision Domains page.

    • Click Add domain on the upper navigation bar.

    • Select Custom domain from the dropdown.

  3. Click Add a custom Domain.

  4. Enter your domain name in the text box.

  5. Re-enter your domain name in the next text box.

  6. Click Confirm.

    Screenshot that shows where to enter the custom domain value.

  7. Make sure the domain name you entered is correct and both text boxes are the same. If needed, click Edit to correct the domain name before confirming.

  8. Click Add.

    Screenshot that shows how to add a custom domain of your choice.

  9. Azure Communication Services creates a custom domain configuration for your domain.

    Screenshot that shows the progress of custom domain Deployment.

  10. To verify domain ownership, click Verify Domain.

    Screenshot that shows custom domain is successfully added for verification. .

  11. To resume the verification later, click Close and resume. Then to continue verification from Provision Domains, click Configure.

    Screenshot that shows the added domain ready for verification in the list of provisioned domains.

  12. When you select either Verify Domain or Configure, it opens the Verify Domain via TXT record dialog box.

    Screenshot that shows the Configure link that you need to click to verify domain ownership.

  13. Add the preceding TXT record to your domain's registrar or DNS hosting provider. Refer to the TXT records section for information about adding a TXT record for your DNS provider.

    Once you complete this step, click Next.

  14. Verify that the TXT record was successfully created in your DNS, then click Done.

  15. DNS changes require 15 to 30 minutes to take effect. Click Close.

    Screenshot that shows the domain verification is in progress.

  16. Once you verify your domain, you can add your SPF and DKIM records to authenticate your domains.

    Screenshot that shows the custom domain is verified.

Configure sender authentication for custom domain

To configure sender authentication for your domains, you need to add more Domain Name Service (DNS) records. This section describes how Azure Communication Services offer records for you to add to your DNS. However, depending on whether the domain you're registering is a root domain or a subdomain, you need to add the records to the respective zone or make changes to the automatically generated records.

This section shows how to add SPF and DKIM records for the custom domain sales.us.notification.azurecommtest.net. The following examples describe four different methods for adding these records to the DNS, depending on the level of the zone where you're adding the records.

  1. Zone: sales.us.notification.azurecommtest.net
Record Type Name Value
SPF TXT sales.us.notification.azurecommtest.net v=spf1 include:spf.protection.outlook.com -all
DKIM CNAME selector1-azurecomm-prod-net._domainkey selector1-azurecomm-prod-net._domainkey.azurecomm.net
DKIM2 CNAME selector2-azurecomm-prod-net._domainkey selector2-azurecomm-prod-net._domainkey.azurecomm.net

The records generated by the portal assume that you are adding these records to the DNS in this zone sales.us.notification.azurecommtest.net.

  1. Zone: us.notification.azurecommtest.net
Record Type Name Value
SPF TXT sales v=spf1 include:spf.protection.outlook.com -all
DKIM CNAME selector1-azurecomm-prod-net._domainkey.sales selector1-azurecomm-prod-net._domainkey.azurecomm.net
DKIM2 CNAME selector2-azurecomm-prod-net._domainkey.sales selector2-azurecomm-prod-net._domainkey.azurecomm.net
  1. Zone: notification.azurecommtest.net
Record Type Name Value
SPF TXT sales.us v=spf1 include:spf.protection.outlook.com -all
DKIM CNAME selector1-azurecomm-prod-net._domainkey.sales.us selector1-azurecomm-prod-net._domainkey.azurecomm.net
DKIM2 CNAME selector2-azurecomm-prod-net._domainkey.sales.us selector2-azurecomm-prod-net._domainkey.azurecomm.net
  1. Zone: azurecommtest.net
Record Type Name Value
SPF TXT sales.us.notification v=spf1 include:spf.protection.outlook.com -all
DKIM CNAME selector1-azurecomm-prod-net._domainkey.sales.us.notification selector1-azurecomm-prod-net._domainkey.azurecomm.net
DKIM2 CNAME selector2-azurecomm-prod-net._domainkey.sales.us.notification selector2-azurecomm-prod-net._domainkey.azurecomm.net

Add SPF and DKIM Records

In this section, you configure the sender authentication by adding Sender Policy Framework (SPF) and DomainKeys Identified Mail (DKIM) records.

  1. Open Provision Domains and confirm that Domain Status is in the Verified state.

  2. To add SPF and DKIM information, click Configure.

  3. Add the following TXT record and CNAME records to your domain's registrar or DNS hosting provider. Refer to the adding DNS records in popular domain registrars table for information about adding a TXT and CNAME record for your DNS provider.

    Screenshot that shows the D N S records that you need to add for S P F validation for your verified domains. Screenshot that shows the D N S records that you need to add for D K I M. Screenshot that shows the D N S records that you need to add for additional D K I M records.

  4. When you're done adding TXT and CNAME information, click Next to continue.

  5. Verify that TXT and CNAME records were successfully created in your DNS. Then click Done.

    Screenshot that shows the DNS records that you need to add for S P F and D K I M.

  6. DNS changes take effect in 15 to 30 minutes. Click Close and wait for verification to complete.

    Screenshot that shows that the sender authentication verification is in progress.

  7. Check the verification status at the Provision Domains page.

    Screenshot that shows that the sender authentication verification is done.

  8. Once you verify sender authentication configurations, your email domain is ready to send emails using the custom domain.

    Screenshot that shows that your verified custom domain is ready to send Email.

Change MailFrom and FROM display names for custom domains

You can optionally configure your MailFrom address to be something other than the default DoNotReply and add more than one sender username to your domain. For more information about how to configure your sender address, see Quickstart: How to add multiple sender addresses.

Your email domain is now ready to send emails.

TXT records

The following links provide instructions about how to add a TXT record using popular domain registrars.

Registrar Name Documentation Link
IONOS by 1 & 1 Steps 1-7
123-reg.co.uk Steps 1-6
Amazon Web Services (AWS) Steps 1-8
Cloudflare Steps 1-6
GoDaddy Steps 1-6
Namecheap Steps 1-9
Network Solutions Steps 1-9
OVH Steps 1-9
web.com Steps 1-8
Wix Steps 1-5
Other (General) Steps 1-4

CNAME records

The following links provide more information about how to add a CNAME record using popular domain registrars. Make sure to use your values from the configuration window rather than the examples in the documentation link.

Registrar Name Documentation Link
IONOS by 1 & 1 Steps 1-10
123-reg.co.uk Steps 1-6
Amazon Web Services (AWS) Steps 1-8
Cloudflare Steps 1-6
GoDaddy Steps 1-6
Namecheap Steps 1-8
Network Solutions Steps 1-9
OVH Steps 1-8
web.com Steps 1-8
Wix Steps 1-5
Other (General) Guide

Next steps