1. Home
  2. Hosting
  3. cPanel
  4. How to setup an SPF record (cPanel)

How to setup an SPF record (cPanel)

A Sender Policy Framework (SPF) record is a type of Domain Name Service (DNS) TXT record that identifies which mail servers are permitted to send email on behalf of your domain. The purpose of an SPF record is to detect and prevent spammers from sending messages with forged “from” addresses on your domain.  


The symptoms of Email Spoofing include a large number of ‘Non-delivery Emails’ entering your inbox sporadically. These are emails that have been sent from another email address, but because the emails have had the ‘From’ address forged to look like your email address, any emails that have failed to be delivered will be delivered to your inbox. 


This is quite common because the vast majority of ‘spoof’ emails are known to be spam by most email platforms, meaning most if not all emails will never be delivered to the intended recipient and will instead generate a ‘Non-delivery report’. 


Adding an SPF record can help prevent others from spoofing your domain. For example, Office365 provides you with the record to add. You would then need to add it to your DNS zone. 


1. Log in to cPanel. 


2. Click on “Zone Editor”. 




3. Click on “Manage” next to your domain name.  




4. You are now able to add a new record if one does not exist for it already or if one does exist, you can simply edit it. 




“Name” should be the domain name. 

You can keep the TTL (time to live) the same as the others that have already been created if you were not given one. 

TXT Data is the “rule” that you wish to apply. 


For example, if your organisation uses only MS Office 365 and you do not have local mail servers, your SPF record should look like this: 


Updated on October 19, 2023

Was this article helpful?

Related Articles