Skip to main content
Enter TitanOS

DNS host guide

Cloudflare DMARC Setup: SPF, DKIM and DMARC

If your nameservers are Cloudflare's, every email record belongs in the Cloudflare DNS page, whatever registrar you bought the domain from. Cloudflare also offers a free DMARC Management screen that collects the reports for you.

Cloudflare is where many Australian businesses end up for DNS, often after a web developer moved the nameservers. That creates the most common mistake in this whole topic: the owner logs in to the registrar, adds SPF and DMARC there, and nothing happens, because the registrar is no longer the DNS host.

Cloudflare also differs from a registrar in one useful way. It runs DMARC Management, a dashboard that receives your aggregate reports and shows them as charts, so you do not need to read raw XML. This page covers both routes: the plain DNS records and the DMARC Management screen.

What we checked. Read on 28 November 2026: Cloudflare developer docs on creating DNS records, DNS record types, enabling DMARC Management and its security records page. Cloudflare's pages do not describe the Name box for TXT records specifically, so the Name guidance below is the standard rule plus a check you can run yourself.

Step 1: Confirm Cloudflare is your DNS, then open DNS Records

  1. Sign in to the Cloudflare dashboard, select your account and the domain, and open the DNS Records page.
  2. Confirm the domain's nameservers at the registrar are Cloudflare's. If they are not, this dashboard is not live for the domain.
  3. Select Add record, choose the Type, fill in the fields for that type and select Save. Cloudflare's docs list TTL as the field controlling how long the record is valid, and Comment and Tag as fields for your reference.
  4. Search the list for TXT records starting v=spf1 and for _dmarc before adding.

What goes in Name, Content and TTL at Cloudflare

Enter the short name (_dmarc, or selector1._domainkey) and check the list afterwards: Cloudflare shows the full name with your domain on the end. If you see your domain twice, you typed it in the Name box.

Quoting: Cloudflare's docs say TXT content is one or more strings in double quotes, that inconsistent quotation marks cause a validation error, and that if you save content without any quotes, Cloudflare adds them for you. So paste the value plain, with no quotes.

Proxy status: for A, AAAA and CNAME records you choose whether traffic is proxied. A DKIM CNAME is not web traffic, so set it to DNS only. A proxied CNAME will not return the key the mail service is looking for.

RecordTypeName or hostValue
SPFTXT@v=spf1 include:_spf.google.com ~all (Google Workspace example)
DKIM (Microsoft 365)CNAMEselector1._domainkey and selector2._domainkey (proxy status: DNS only)the two targets from the Defender portal
DMARCTXT_dmarcv=DMARC1; p=none; rua=mailto:dmarc-reports@yourbusiness.com.au

Replace yourbusiness.com.au with your own domain. The example reporting mailbox is only a placeholder.

Step 2: SPF at Cloudflare

Add a TXT record, Name @, with your SPF line. The include comes from your mail platform. Cloudflare's DMARC Management documentation adds one warning worth knowing: it does not support SPF changes through its screen when a CNAME in your zone points to an external domain, and changes to SPF can invalidate your DMARC policy, so manage those SPF updates at the external provider.

One v=spf1 record per name. Edit the existing one.

v=spf1 include:_spf.google.com ~all

Step 3: DKIM at Cloudflare

Cloudflare publishes the DKIM record your mail platform gives you. Microsoft 365 uses two CNAMEs, Google Workspace uses one TXT named google._domainkey.

  1. Generate the DKIM details in your mail platform.
  2. In DNS Records, Add record, choose CNAME or TXT to match.
  3. For CNAME records, set proxy status to DNS only.
  4. Save, then switch signing on in the mail platform once the record is live.

Step 4: DMARC at Cloudflare, by hand or with DMARC Management

By hand: add a TXT record named _dmarc at p=none, with your own rua address. Done.

With DMARC Management: in the dashboard go to Email, then DMARC Management, then Enable DMARC Management. Cloudflare scans your zone. If no DMARC record exists it offers to add one you can edit later. If one exists it adds a second rua address pointing at Cloudflare, so your own address and Cloudflare both receive reports. Cloudflare says the first report can take up to 24 hours. This only works on the apex domain (for example example.com, not blog.example.com) and not on subdomain setups.

Email, DMARC Management, Email record overview, View records also lets you set up SPF, DKIM and DMARC and lists records you already have. Cloudflare's dashboard does not move your policy from none to quarantine to reject for you; you edit the _dmarc TXT record yourself when the time comes.

v=DMARC1; p=none; rua=mailto:dmarc-reports@yourbusiness.com.au

A safe rollout: p=none, then quarantine, then reject

The reason for staging is simple. DMARC tells every receiving mail system what to do with mail that claims to be from your domain but fails SPF and DKIM. If one of your own systems (the invoicing tool, the booking software, the newsletter service) is not set up yet, going straight to reject throws away your own legitimate mail. Starting at p=none changes nothing for your mail and gives you the reports to find those systems first. The timeline below works the same way at Cloudflare as anywhere else; only where you type the record changes.

StageWhenRecordWhat to doMove on when
1. WatchDay 0 to week 4v=DMARC1; p=none; rua=mailto:dmarc-reports@example.com.auPublish the record and change nothing else. Read the daily aggregate reports and list every system that sends as your domain: your mail platform, your invoicing tool, your newsletter service, your booking system, your website contact form.Every legitimate sender passes SPF or DKIM in the reports for two weeks in a row, and you can explain every unknown sending address.
2. Quarantine, small sliceWeek 4 to week 8v=DMARC1; p=quarantine; pct=10; rua=mailto:dmarc-reports@example.com.auAsk receivers to treat 10 percent of failing mail as suspicious. Raise it to 25, then 50 once a week, checking the reports and asking staff whether anything real went missing.Two clean weeks at pct=50 with no legitimate mail failing.
3. Quarantine, allWeek 8 to week 10v=DMARC1; p=quarantine; pct=100; rua=mailto:dmarc-reports@example.com.auAll failing mail is treated as suspicious. This is the safe place to pause if you run a lot of third-party senders.Two clean weeks at pct=100.
4. RejectWeek 10 onwardv=DMARC1; p=reject; rua=mailto:dmarc-reports@example.com.auFailing mail is refused. Keep reading the reports monthly, and add any new sending service to SPF and DKIM before it goes live.You are done. Review again whenever you add or retire a sending service.

The weeks are our recommended rhythm for a small business with a handful of senders, not a standard. Microsoft's and Google's documentation both say to start at p=none, move to quarantine, then reject, and to go slowly. Microsoft suggests widening quarantine with pct in steps of 10, 25, 50, 75 and 100. Replace dmarc-reports@example.com.au with a mailbox you will really read.

Check it worked with the free spoofing check

Run your domain through the free email spoofing check. It reads public DNS only: it does not log in to anything, send anything or touch your mail. After each step you should see the matching result change.

  1. After SPF: one SPF record is found, and it lists your mail platform.
  2. After DKIM: the selector you published is found and is a valid key.
  3. After DMARC: a record is found at _dmarc, the policy reads none, and a reporting address is present.
  4. At every later change: the policy reads quarantine or reject, and the percentage is what you set.

Cloudflare changes tend to be visible quickly. Run the free check straight after saving, then again after the next DMARC Management report arrives.

You can also read the records yourself. In a Windows command prompt, nslookup -type=TXT _dmarc.yourbusiness.com.aushows the DMARC record, and Microsoft's documentation uses the same command to check for syntax errors or more than one _dmarc record. If the answer is empty, the likeliest causes at Cloudflare are a typo in the name, a record saved in a screen your nameservers do not use, or not enough waiting time.

Cloudflare gotchas

  • Registrar records are ignoredIf Cloudflare holds your nameservers, records added at GoDaddy, VentraIP or anywhere else do nothing.
  • DKIM CNAMEs must be DNS onlyA proxied CNAME hides the target the mail platform needs.
  • No quotes neededCloudflare adds double quotes if you save without them, and rejects inconsistent quoting.
  • Apex only for DMARC ManagementSubdomains and subdomain setups are not supported by that screen. Use plain DNS records for them.
  • Extra rua is added automaticallyEnabling DMARC Management appends Cloudflare's reporting address to an existing record. Expect to see it when you next read the line.

Questions people ask

Does Cloudflare set up DMARC for me?
Only if you enable DMARC Management, which offers to add a record if none exists. It does not move your policy from none to reject for you.
Should DKIM CNAMEs be proxied in Cloudflare?
No. Set them to DNS only so the mail platform can read the key.
Why did my registrar's DMARC record not work?
If your nameservers are Cloudflare's, only the Cloudflare zone counts. Add the record in Cloudflare.

Official sources used

Want it done and checked for you?

The Email Spoofing Shield guide in the TITANOS shop covers SPF, DKIM and DMARC for Microsoft 365, Google Workspace and cPanel hosting, with record templates, a sender inventory worksheet and a staged DMARC plan, for the days you would rather follow a document than a web page. If you would rather talk it through with a person, book a free audit call with Kyle.

Book a free call