↑ ↓ select, Enter open, Esc close

Show the SPF record of a domain

Adjust the values, the command updates live
user@server
dig +short example.com TXT | grep -i "v=spf1"

Shows the SPF record, which defines which servers may send mail on behalf of the domain. Your own mail server’s IP must be covered by it, for example via ip4:, a, mx or include:. A domain may only have one SPF record, two records cause an error.

Note: SPF allows at most ten DNS lookups (include, a, mx and similar), beyond that the check fails.

Also searched as

  • check spf record
  • emails going to spam spf
  • find spf fail cause

Related one-liners

All in DNS

Read first, then run.

The commands on myline.de act directly on servers, files and databases. A wrong path or placeholder can delete data irreversibly or make a server unreachable.

  • All commands are provided without warranty and are not tested on every system.
  • Understand what a command does before running it, and check every placeholder.
  • Make a backup first and, if possible, try it on a test system.
  • You run commands at your own risk. Liability for damages is excluded to the extent permitted by law.