To configure an SPF record, you need to add a TXT record in your DNS settings. The record should include all the IP addresses and third-party services authorized to send emails on behalf of your domain. For example:
v=spf1 include:_spf.google.com ~all
This SPF record authorizes Google's servers to send emails for your domain. The "~all" directive means that emails from unauthorized sources will be marked as "soft fail."