{"id":1059,"date":"2016-05-31T21:34:21","date_gmt":"2016-06-01T02:34:21","guid":{"rendered":"https:\/\/hostease.com\/blog\/?p=1059"},"modified":"2025-02-05T03:50:58","modified_gmt":"2025-02-05T08:50:58","slug":"how-to-add-dkim-and-spf-records-using-cpanel","status":"publish","type":"post","link":"https:\/\/www.hostease.com\/blog\/cpanel\/how-to-add-dkim-and-spf-records-using-cpanel\/","title":{"rendered":"How To Add DKIM And SPF Records Using cPanel"},"content":{"rendered":"\n<p>One commonly overlooked area in cPanel is email authentication. Maybe it\u2019s one of those things that you never bothered checking out, or maybe it just looked a little intimidating.<\/p>\n\n\n\n<p>Regardless of whether you know it is there or what it does you may want to look at it when you get a moment of spare time. It can potentially reduce the spam mail that you receive as well as increase the chance that the mail you send out arrives in someone\u2019s inbox instead of a junk\/spam folder. You do want your messages delivered to someone\u2019s inbox don\u2019t you?<\/p>\n\n\n\n<p><strong>cPanel email authentication<\/strong> allows you to enable DKIM keys, and SPF records for your domain very easy.<\/p>\n\n\n\n<p><strong>Here is a little more information about each:<\/strong><\/p>\n\n\n\n<p><strong>DKIM (DomainKeys Identified Mail)<\/strong> \u2013 is used to verify that an inbound email message is actually from the stated sender, and that the message has not been altered or tampered with. If you enable DKIM, messages are digitally signed using a private key. The message recipient uses DNS to retrieve the sender\u2019s public key in order to verify the message\u2019s signature. If the signature is invalid, then the message is assumed to be forged and spam.<\/p>\n\n\n\n<p>http:\/\/en.wikipedia.org\/wiki\/DomainKeys_Identified_Mail<br><a title=\"DKIM\" href=\"http:\/\/www.dkim.org\/\" target=\"_blank\" rel=\"noopener\">http:\/\/www.dkim<\/a>.<a title=\"DKIM\" href=\"http:\/\/www.dkim.org\/\" target=\"_blank\" rel=\"noopener\">org\/<\/a><\/p>\n\n\n\n<p><strong>SPF (Sender Policy Framework)<\/strong> \u2013 specifies which mail servers are permitted to send mail on behalf of your domain. Some mail servers don\u2019t accept incoming messages if it comes from a domain that doesn\u2019t have an SPF record. Without an SPF record a message may end up in the receivers spam\/junk folder, or it may be rejected completely.<\/p>\n\n\n\n<p>http:\/\/en.wikipedia.org\/wiki\/Sender_Policy_Framework<br>http:\/\/www.openspf.org\/<\/p>\n\n\n\n<p>Enabling DKIM and SPF can help reduce the amount of spam you receive, and increase the likelihood that the messages you send out will arrive in the receivers inbox rather than in their spam\/junk folder. There are obviously no guarantees, and this assumes that your host has set up the mail server and records properly to begin with. It also assumes that the IP address that your website happens to be on or using isn\u2019t blacklisted for some reason.<\/p>\n\n\n\n<p>Before enabling either of these, make sure you have a good understanding of what they do. Adding a SPF record is a little more confusing in cPanel than DKIM. If you are not sure about the process, then you may want to ask your host for help.<\/p>\n\n\n\n<p>After adding\/enabling one or both you should allow 24-48 hours (usually less) for the DNS records to propagate.<\/p>\n\n\n\n<p>If for some reason you added a custom SPF record in the past you would want to combine them rather than have two separate records.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">How To Enable DKIM And SPF In cPanel<\/h3>\n\n\n\n<p>Login to your cPanel account.<\/p>\n\n\n\n<p>Locate the Mail section\/area.<\/p>\n\n\n\n<p>Select Email Authentication.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Email-Authentication.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"835\" src=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Email-Authentication-1024x835.png\" alt=\"\" class=\"wp-image-2249\" title=\"cPanel Email Authentication\" srcset=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Email-Authentication-1024x835.png 1024w, https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Email-Authentication-300x245.png 300w, https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Email-Authentication-768x626.png 768w, https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Email-Authentication.png 1210w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Scroll down to DKIM and click the Enable button.<\/p>\n\n\n\n<p>Come back to the SPF section and click the Enable button for SPF.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Enable-button-for-SPF.png\"><img loading=\"lazy\" decoding=\"async\" width=\"585\" height=\"249\" src=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Enable-button-for-SPF.png\" alt=\"\" class=\"wp-image-2250\" srcset=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Enable-button-for-SPF.png 585w, https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/Enable-button-for-SPF-300x128.png 300w\" sizes=\"auto, (max-width: 585px) 100vw, 585px\" \/><\/a><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>After enabling them you should see something like this:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/dkim-enable.png\"><img loading=\"lazy\" decoding=\"async\" width=\"594\" height=\"207\" src=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/dkim-enable.png\" alt=\"\" class=\"wp-image-2252\" title=\"cPanel DKIM SPF Enabled\" srcset=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/dkim-enable.png 594w, https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/dkim-enable-300x105.png 300w\" sizes=\"auto, (max-width: 594px) 100vw, 594px\" \/><\/a><\/figure>\n\n\n\n<p>If you need to customize the SPF record you can do so in the Advanced Settings area underneath the Enable button.<\/p>\n\n\n\n<p><strong>The options are:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Additional Hosts that send mail for your domains (A)<\/li>\n\n\n\n<li>Additional MX servers for your domains (MX)<\/li>\n\n\n\n<li>Additional Ip blocks for your domains (IP4)<\/li>\n\n\n\n<li>Include List (INCLUDE)<\/li>\n\n\n\n<li>All Entry (ALL)<\/li>\n\n\n\n<li>Overwrite Existing Entries<\/li>\n<\/ul>\n\n\n\n<p>You can come back here at any time and update\/change these settings if needed.<\/p>\n\n\n\n<p>If your host has the Advanced DNS Zone Editor available in cPanel in the Domains section\/area you can go there and see that a TXT record for SPF is automatically added for your domain.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">How To Disable DKIM And SPF In cPanel<\/h3>\n\n\n\n<p>To turn off\/disable DKIM or SPF you can return to Email Authentication and simply click on the Disable buttons.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Manually adding SPF<\/h3>\n\n\n\n<p>It is also possible to manually add an SPF record by adding a TXT record using the Advanced DNS Zone Editor. (The Simple DNS Zone Editor won\u2019t allow you to add TXT records.)<\/p>\n\n\n\n<p><strong>Example:<\/strong><br>Name: yourdomain.com.<br>TTL: 14400<br>Type: TXT<br>TXT Data: your actual SPF record<\/p>\n\n\n\n<p>And, click the Add Record button.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/add-spf.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"353\" src=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/add-spf.webp\" alt=\"\" class=\"wp-image-2251\" title=\"Add TXT Record\" srcset=\"https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/add-spf.webp 1024w, https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/add-spf-300x103.webp 300w, https:\/\/www.hostease.com\/blog\/wp-content\/uploads\/2016\/05\/add-spf-768x265.webp 768w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p>It will then show up in the Zone File Records section at the bottom.<\/p>\n\n\n\n<p>For those of you that want to explore manually adding one you can check out the page below for help, but be careful and make sure you know what you are doing.<br>Sender ID Framework SPF Record Wizard by Microsoft<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Testing \u2013 Results<\/h3>\n\n\n\n<p>When I send a message to Hotmail\/Outlook from a domain before enabling DKIM or SPF I can check the message source headers and see that there are none, or they don\u2019t exist.<\/p>\n\n\n\n<p>After enabling both DKIM and SPF in cPanel, and waiting for propagation when I send another email to Hotmail\/Outlook I can see they are present in the headers now.<\/p>\n\n\n\n<p>If I send a message to a Gmail address from a domain with DKIM and SPF enabled and I check the message source headers I can see that they say: pass, and the DKIM-Signature is present.<\/p>\n\n\n\n<p><strong>Note:<\/strong><br>This would be for sending mail from your domain (email address) with the cPanel webmail feature (horde, roundcube, or SquirrelMail), or with an email client program like Mozilla Thunderbird, Outlook, etc.<\/p>\n\n\n\n<p>If you are using a PHP Script like WordPress to send out replies to comments for example, and you are using the default PHP mail function you will want to check the email source headers for these as well. If you don\u2019t see DKIM keys and SPF pass, then consider using an SMTP plugin instead of the PHP mail function. Doing so will allow WordPress to connect and send mail through your hosting SMTP (send mail transfer protocol) with DKIM keys, and SPF records attached.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Learn how to easily add DKIM and SPF records in cPanel to improve email security and prevent spam. Follow our step-by-step guide for better email authentication and increased inbox delivery rates.<\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[89],"tags":[482,480,481,483],"class_list":["post-1059","post","type-post","status-publish","format-standard","hentry","category-cpanel","tag-cpanel-email-authentication","tag-dkim","tag-email-security-setup","tag-spf-records"],"aioseo_notices":[],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/posts\/1059","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/comments?post=1059"}],"version-history":[{"count":3,"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/posts\/1059\/revisions"}],"predecessor-version":[{"id":2253,"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/posts\/1059\/revisions\/2253"}],"wp:attachment":[{"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/media?parent=1059"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/categories?post=1059"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hostease.com\/blog\/wp-json\/wp\/v2\/tags?post=1059"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}