Back to dashboard

Google Workspace: SPF, DKIM and DMARC

What this guide is for

Emails sent from Gmail with your domain go through Google's servers. To be authenticated, your domain must authorize Google in its SPF record and publish the DKIM key generated in the Admin console. Without DKIM, Google signs with a technical domain that is not aligned with your From address.

Expected records

Type Name (host) Value
TXT (SPF) your domain (@) v=spf1 include:_spf.google.com ~all (or the include added to your existing SPF record)
TXT (DKIM) google._domainkey the v=DKIM1; k=rsa; p=... value generated in the Admin console
TXT (DMARC) _dmarc v=DMARC1; p=none; rua=mailto:[email protected]
MX your domain smtp.google.com (newer domains) or aspmx.l.google.com and its backup servers
  • google is the default selector prefix. Keep it unless it is already used on your domain.
  • Choose a 2048-bit key if your DNS host supports it, otherwise 1024 bits.
  • One SPF record per domain: if other tools send on your behalf, merge their includes into the same record.

Steps in the Admin console

You must be signed in with a super administrator account.

  1. Open the Google Admin console (admin.google.com).
  2. Go to Apps > Google Workspace > Gmail, then open Authenticate email.
  3. Select the domain, then click Generate new record.
  4. Select the key length (2048 bits preferred), keep the google prefix and click Generate.
  5. Copy the DNS host name and TXT record value shown, then create the TXT record at your DNS host.
  6. Wait until the record is published (up to 48 hours), return to Authenticate email and click Start authentication. Do not click it before the record is visible in DNS.

The key can only be generated 24 to 72 hours after Gmail is turned on for the organization. Each domain (including secondary domains) needs its own key.

Check the setup

  1. In Authenticate email, the status should show that email is being authenticated with DKIM. The message asking you to update DNS records may persist for up to 48 hours.
  2. Send an email to another Gmail or Google Workspace address (not to yourself), open Show original and check for DKIM: PASS and SPF: PASS.
  3. Run a new scan in this tool: the google selector should be detected.

DMARC

Publish a single TXT record at _dmarc.<your domain>, starting with monitoring:

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

Read the reports for a few weeks, check that all your legitimate mail passes, then move gradually to p=quarantine and p=reject. Google requires SPF, DKIM and DMARC from bulk senders.

Official documentation

Google Workspace: setup guide - SEKOIA