Skip to main content
All Collections👩‍💻 Mastering DNS: A Comprehensive Guide to DNS Records
The Complete Guide to Setting Up DNS Records for Better Email Deliverability
The Complete Guide to Setting Up DNS Records for Better Email Deliverability

Ensure your emails perform well by setting up your DNS records properly. Here's how. 🚀

Updated over a week ago

If you've landed here, you're probably trying to figure out how to fix issues with your DNS records and ensure your emails land in the inbox, not the spam folder. Let's break down what DNS records are, why they matter, and how to set them up for email success.


What Are DNS Records?

DNS (Domain Name System) records are like an address book for the internet. They map your domain name (like yourwebsite.com) to IP addresses, guiding web traffic and email to the right destinations. Think of DNS as the middleman connecting your domain to its web server or email server.

Key DNS Record Types

  1. A Record: Points your domain to an IP address.

  2. AAAA Record: Like the A record but for IPv6 addresses.

  3. CNAME Record: Redirects one domain to another.

  4. NS (Nameserver) Record: Specifies the servers managing your DNS records.

  5. TXT Record: Stores text-based information for verification, including email security protocols.

  6. MX Record: Directs incoming emails to the correct email server.

For email deliverability, TXT and MX records are the key players.


Why Do DNS Records Matter for Emails?

Without the right DNS setup, your emails might not get delivered. The three essential DNS records for email security and deliverability are:

  1. SPF (Sender Policy Framework)

  2. DKIM (DomainKeys Identified Mail)

  3. DMARC (Domain-based Message Authentication, Reporting, and Conformance)

These records work together to ensure your emails are authenticated, protecting your domain’s reputation and increasing the likelihood that your messages reach the inbox.


How to Set Up SPF, DKIM, and DMARC Records

1. Setting Up an SPF Record

An SPF record is a TXT record that tells email servers which IPs or domains are authorized to send emails on your behalf.

Example SPF Record:

v=spf1 a mx include:_spf.yourprovider.com ~all

How to Add an SPF Record:

  1. Log into your domain host (e.g., GoDaddy, Namecheap, Cloudflare).

  2. Navigate to the DNS management section.

  3. Add a new TXT record with:

    • Host: Your domain name (or @ for root domain).

    • Value: Your SPF record (e.g., v=spf1 a mx include:_spf.yourprovider.com ~all).

    • TTL: Set to 3600 seconds or use the default.

  4. Save changes.

Tip: Use tools like SPF Record Checker to verify your SPF setup.


2. Setting Up a DKIM Record

DKIM adds a digital signature to your emails, verifying that they haven’t been altered during transit.

How DKIM Works:

  1. Your email provider gives you a public/private key pair.

  2. The private key signs outgoing emails, and the public key is added as a TXT record in your DNS.

  3. Recipient servers verify the signature using your public key.

How to Add a DKIM Record:

  1. Get the DKIM key from your email provider (e.g., Google Workspace, Microsoft 365).

  2. Add it as a TXT record in your DNS:

    • Host: Typically, something like default._domainkey.

    • Value: Your DKIM public key.

  3. Save the record.

Verification: Use tools like DKIM Core to confirm your DKIM setup.


3. Setting Up a DMARC Record

DMARC works with SPF and DKIM to give you control over how unauthenticated emails are handled.

Example DMARC Record:

v=DMARC1; p=quarantine; rua=mailto:[email protected]

How to Add a DMARC Record:

  1. Add a new TXT record in your DNS:

    • Host: _dmarc.

    • Value: Your DMARC policy (e.g., v=DMARC1; p=reject; rua=mailto:[email protected]).

  2. Save the record.

DMARC Policy Options:

  • p=none: Monitor emails but take no action.

  • p=quarantine: Mark unauthenticated emails as spam.

  • p=reject: Block unauthenticated emails entirely.

Check Your DMARC Setup: Tools like DMARC Analyzer can help you verify and monitor your setup.


Why You DO NOT need to add lemlist to your SPF record?

lemlist uses your SMTP server for sending emails, so there's no need to include it in your SPF record.


Benefits of Proper DNS Configuration

  1. Improved Deliverability: SPF, DKIM, and DMARC work together to authenticate your emails, boosting their chances of reaching inboxes.

  2. Domain Protection: Prevent spoofing and phishing attempts by bad actors.

  3. Reputation Management: Secure your domain’s standing with email providers.


If you're stuck or need help setting up your DNS records, don’t hesitate to reach out to our support team. Proper DNS setup is the foundation of successful email campaigns. Let's get it right! 🚀

For more insights, check out our related guides:

Have questions? Let us know—we're here to help! 😊

Did this answer your question?