{"id":15406,"date":"2024-10-18T06:36:55","date_gmt":"2024-10-18T06:36:55","guid":{"rendered":"https:\/\/truehost.com\/support\/?post_type=docs&#038;p=15406"},"modified":"2024-10-28T12:11:08","modified_gmt":"2024-10-28T12:11:08","password":"","slug":"configuring-dkim-and-spf-for-email-security","status":"publish","type":"docs","link":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/","title":{"rendered":"Configuring DKIM and SPF for Email Security"},"content":{"rendered":"\n<p>Configuring <strong>DomainKeys Identified Mail (DKIM)<\/strong> and <strong>Sender Policy Framework (SPF)<\/strong> is essential for improving email deliverability and preventing phishing or spoofing attacks. <\/p>\n\n\n\n<p>These protocols validate that emails are sent from trusted sources, thereby helping your emails avoid spam filters and maintain authenticity. Here\u2019s a comprehensive guide on configuring DKIM and SPF for robust email security.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">What are DKIM and SPF?<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>DKIM<\/strong> adds a cryptographic signature to emails, which receiving servers can verify. This ensures that the message has not been altered in transit and originates from a domain with an authorized key.<\/li>\n\n\n\n<li><strong>SPF<\/strong> allows the domain owner to specify which IP addresses are authorized to send emails on behalf of their domain. This prevents unauthorized servers from sending emails as if they\u2019re from your domain.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Step 1: Configure SPF<\/strong><\/h3>\n\n\n\n<p><strong>Determine Authorized IP Addresses<\/strong><\/p>\n\n\n\n<p>Identify all IP addresses used to send emails on behalf of your domain. This includes:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Your mail server IP.<\/li>\n\n\n\n<li>Third-party services (if applicable) e.g., Mailgun, SendGrid, Amazon SES, google workspace<\/li>\n<\/ul>\n\n\n\n<p><strong>Create an SPF Record<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>An SPF record is a TXT record in your domain\u2019s DNS settings.<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>v=spf1 +mx +a +ip4:203.0.113.2 include:_spf.google.com -all<\/code><\/pre>\n\n\n\n<ul class=\"wp-block-list\">\n<li>In the above record\n<ul class=\"wp-block-list\">\n<li><code>v=spf1<\/code>: Indicates that this is an SPF record, version 1.<\/li>\n\n\n\n<li><code>ip4:203.0.113.2<\/code>: Specifies an authorized sending IP address.<\/li>\n\n\n\n<li><code>include:_spf.google.com<\/code>: Authorizes Google\u2019s mail servers to send on behalf of your domain (useful if you\u2019re using Google Workspace).<\/li>\n\n\n\n<li><code>-all<\/code>: Denies any server not specified in the record from sending email on behalf of the domain.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>I&#8217;m sending emails from server 91.134.244.66 thus nmy spf will look like below<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>v=spf1 +mx +a +ip4:91.134.244.66 ~all<\/code><\/pre>\n\n\n\n<p><strong>Add the SPF Record to Your DNS<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Log in to your DNS provider (e.g., <strong><a href=\"https:\/\/truehost.com\/support\/knowledge-base\/manage-and-reset-dns-records-using-zone-editor-in-cpanel\/\" target=\"_blank\" rel=\"noreferrer noopener\">Truehost Cpanel<\/a><\/strong>, <strong><a href=\"https:\/\/truehost.com\/support\/knowledge-base\/how-to-register-on-olitt-and-manage-domain-dns\/\" target=\"_blank\" rel=\"noreferrer noopener\">Olitt DNS Manager<\/a><\/strong>, <strong><a href=\"https:\/\/developers.cloudflare.com\/fundamentals\/setup\/\" target=\"_blank\" rel=\"noreferrer noopener\">Cloudflare<\/a><\/strong>, etc).<\/li>\n<\/ul>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Locate the option to add a <strong>TXT<\/strong> record.For the name, you can leave it blank or use <code>@<\/code> to apply to your root domain.<\/li>\n<\/ul>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Paste your SPF record in the value field.Save the record.<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-full is-style-zoooom\"><img loading=\"lazy\" decoding=\"async\" width=\"1003\" height=\"199\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570.png\" alt=\"\" class=\"wp-image-15918\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570.png 1003w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570-300x60.png 300w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570-768x152.png 768w\" sizes=\"auto, (max-width: 1003px) 100vw, 1003px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Step 2: Configure DKIM<\/strong><\/h3>\n\n\n\n<p>DKIM requires generating a public-private key pair, where the private key signs outgoing messages, and the public key is added as a DNS record<\/p>\n\n\n\n<p><strong>Generate DKIM Keys<\/strong><\/p>\n\n\n\n<p>This would differ depending on your email server software, here are general methods:<\/p>\n\n\n\n<p><strong>A. On Linux (Postfix): Use OpenSSL to generate keys.<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><strong>mkdir -p \/etc\/dkim\nopenssl genrsa -out \/etc\/dkim\/domain.private 2048\nopenssl rsa -in \/etc\/dkim\/domain.private -pubout -out \/etc\/dkim\/domain.public<\/strong><\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large is-resized is-style-zoooom\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"400\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-571-1024x400.png\" alt=\"\" class=\"wp-image-15921\" style=\"width:840px;height:auto\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-571-1024x400.png 1024w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-571-300x117.png 300w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-571-768x300.png 768w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-571.png 1056w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Your keys are now in this directory <strong>\/etc\/dkim<\/strong> as in the image below.<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"218\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-573-1024x218.png\" alt=\"\" class=\"wp-image-15925\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-573-1024x218.png 1024w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-573-300x64.png 300w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-573-768x163.png 768w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-573.png 1151w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p><strong>B. Using cPanel or Plesk: <\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Both cPanel and Plesk have built-in DKIM tools that automatically generate and publish the keys in DNS.<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-large is-style-zoooom\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"470\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-572-1024x470.png\" alt=\"\" class=\"wp-image-15923\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-572-1024x470.png 1024w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-572-300x138.png 300w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-572-768x352.png 768w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-572.png 1049w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p><strong>Add DKIM Public Key to DNS<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>After generating keys, convert the public key into a TXT record.<\/li>\n\n\n\n<li>Open the public key file and copy its contents.<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-full is-style-zoooom\"><img loading=\"lazy\" decoding=\"async\" width=\"783\" height=\"214\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-574.png\" alt=\"\" class=\"wp-image-15928\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-574.png 783w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-574-300x82.png 300w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-574-768x210.png 768w\" sizes=\"auto, (max-width: 783px) 100vw, 783px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Create a new TXT record in your DNS (e.g., <strong><a href=\"https:\/\/truehost.com\/support\/knowledge-base\/manage-and-reset-dns-records-using-zone-editor-in-cpanel\/\" target=\"_blank\" rel=\"noreferrer noopener\">Truehost Cpanel<\/a><\/strong>, <strong><a href=\"https:\/\/truehost.com\/support\/knowledge-base\/how-to-register-on-olitt-and-manage-domain-dns\/\" target=\"_blank\" rel=\"noreferrer noopener\">Olitt DNS Manager<\/a><\/strong>, <strong><a href=\"https:\/\/developers.cloudflare.com\/fundamentals\/setup\/\" target=\"_blank\" rel=\"noreferrer noopener\">Cloudflare<\/a><\/strong>, etc). with the following format:\n<ul class=\"wp-block-list\">\n<li><strong>Name<\/strong>: <code>selector._domainkey<\/code>, where <code>selector<\/code> is a unique identifier (e.g., <code>default<\/code>, <code>s1<\/code>, <code>dkim1<\/code>).<\/li>\n\n\n\n<li>Value to be as below. Replace <code>YourPublicKey<\/code> with the actual contents of your public key, omitting any line breaks or extra spaces.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code><strong>v=DKIM1; k=rsa; p=YourPublicKey<\/strong><\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-full is-style-zoooom\"><img loading=\"lazy\" decoding=\"async\" width=\"952\" height=\"220\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-575.png\" alt=\"\" class=\"wp-image-15930\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-575.png 952w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-575-300x69.png 300w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-575-768x177.png 768w\" sizes=\"auto, (max-width: 952px) 100vw, 952px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Some DNS management platforms could need that you split your DKIM into two, it it is too long. See <strong><a href=\"https:\/\/support.cpanel.net\/hc\/en-us\/articles\/4402114117911-Why-are-DKIM-TXT-records-split\" target=\"_blank\" rel=\"noreferrer noopener\">this<\/a><\/strong> documentation on why there may be need to split it.<\/li>\n<\/ul>\n\n\n\n<p>You can use a <strong><a href=\"https:\/\/www.mailhardener.com\/tools\/dns-record-splitter\" target=\"_blank\" rel=\"noreferrer noopener\">DKIM Splitter <\/a><\/strong>to split the DKIM record before adding it to your DNS<\/p>\n\n\n\n<p><strong>Configure Your Email Server to Sign Emails with DKIM<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>If you are using postfix, then install <code>opendkim<\/code> and configure it to use the private key.  <\/li>\n\n\n\n<li>If you use Almalinux or other <strong>RHEL<\/strong> Bases systems use the command below<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code><strong>yum install opendkim opendkim-tools -y<\/strong><\/code><\/pre>\n\n\n\n<ul class=\"wp-block-list\">\n<li>If you use Ubuntu or other <strong>RHEL<\/strong> Bases systems use the command below<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code><strong>sudo apt install opendkim opendkim-tools -y<\/strong><\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large is-style-zoooom\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"250\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-576-1024x250.png\" alt=\"\" class=\"wp-image-15937\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-576-1024x250.png 1024w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-576-300x73.png 300w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-576-768x188.png 768w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-576.png 1080w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Edit <code>\/etc\/opendkim.conf<\/code> to configure signing and adjust the following lines accordingly. They could be existing alreasy, so just edit them with relevant information as below.<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>Domain                 example.com\nKeyFile                \/etc\/dkim\/domain.private\nSelector               default\nSocket                 inet:12301@localhost<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"739\" height=\"199\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-577.png\" alt=\"\" class=\"wp-image-15942\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-577.png 739w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-577-300x81.png 300w\" sizes=\"auto, (max-width: 739px) 100vw, 739px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Restart Postfix and OpenDKIM to apply changes:<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code><strong>sudo systemctl restart opendkim postfix<\/strong><\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Step 3: Verify SPF and DKIM Records<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>After setting up SPF and DKIM, you can verify them using tools like <a href=\"https:\/\/mxtoolbox.com\/SuperTool.aspx#\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>MxToolBox<\/strong>.<\/a>\n<ul class=\"wp-block-list\">\n<li><strong>SPF Verification<\/strong>: Run an SPF lookup at <a>MxToolBox<\/a> to confirm the record is correctly configured.<\/li>\n\n\n\n<li><strong>DKIM Verification<\/strong>: Send a test email to a service like <a href=\"https:\/\/www.mail-tester.com\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Mail Tester<\/strong><\/a>, which will analyze your DKIM signature.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1004\" height=\"653\" src=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-578.png\" alt=\"\" class=\"wp-image-15948\" srcset=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-578.png 1004w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-578-300x195.png 300w, https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-578-768x500.png 768w\" sizes=\"auto, (max-width: 1004px) 100vw, 1004px\" \/><\/figure>\n\n\n\n<p>By setting up SPF and  DKIM, you\u2019ll improve your domain\u2019s reputation, reduce spam incidents, and protect your brand against phishing attacks. This configuration helps your legitimate emails reach recipients\u2019 inboxes while filtering out unauthorized messages.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Configuring DomainKeys Identified Mail (DKIM) and Sender Policy Framework (SPF) is essential for improving email deliverability and preventing phishing or spoofing attacks. These protocols validate that emails are sent from trusted sources, thereby helping your emails avoid spam filters and maintain authenticity. Here\u2019s a comprehensive guide on configuring DKIM and SPF for robust email security. [&hellip;]<\/p>\n","protected":false},"author":9,"featured_media":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"_eb_attr":"","_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"footnotes":""},"doc_category":[1881,1820,1824,1827,1879,2128],"doc_tag":[],"class_list":["post-15406","docs","type-docs","status-publish","hentry","doc_category-business-email","doc_category-cloud-servers-in-kenya","doc_category-dedicated-servers","doc_category-emails","doc_category-servers","doc_category-vps-servers"],"year_month":"2026-07","word_count":780,"total_views":"0","reactions":{"happy":"49","normal":"0","sad":"0"},"author_info":{"name":"Eugene","author_nicename":"eugene","author_url":"https:\/\/truehost.com\/support\/author\/eugene\/"},"doc_category_info":[{"term_name":"Business Email","term_url":"https:\/\/truehost.com\/support\/docs-category\/business-email\/"},{"term_name":"Cloud servers in Kenya","term_url":"https:\/\/truehost.com\/support\/docs-category\/cloud-servers-in-kenya\/"},{"term_name":"dedicated servers","term_url":"https:\/\/truehost.com\/support\/docs-category\/dedicated-servers\/"},{"term_name":"Emails","term_url":"https:\/\/truehost.com\/support\/docs-category\/emails\/"},{"term_name":"Servers","term_url":"https:\/\/truehost.com\/support\/docs-category\/servers\/"},{"term_name":"VPS-Servers","term_url":"https:\/\/truehost.com\/support\/docs-category\/vps-servers\/"}],"doc_tag_info":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.0 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Configuring DKIM and SPF for Email Security -<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Configuring DKIM and SPF for Email Security -\" \/>\n<meta property=\"og:description\" content=\"Configuring DomainKeys Identified Mail (DKIM) and Sender Policy Framework (SPF) is essential for improving email deliverability and preventing phishing or spoofing attacks. These protocols validate that emails are sent from trusted sources, thereby helping your emails avoid spam filters and maintain authenticity. Here\u2019s a comprehensive guide on configuring DKIM and SPF for robust email security. [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/\" \/>\n<meta property=\"article:modified_time\" content=\"2024-10-28T12:11:08+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570.png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/knowledge-base\\\/configuring-dkim-and-spf-for-email-security\\\/\",\"url\":\"https:\\\/\\\/truehost.com\\\/support\\\/knowledge-base\\\/configuring-dkim-and-spf-for-email-security\\\/\",\"name\":\"Configuring DKIM and SPF for Email Security -\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/knowledge-base\\\/configuring-dkim-and-spf-for-email-security\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/knowledge-base\\\/configuring-dkim-and-spf-for-email-security\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/truehost.com\\\/support\\\/wp-content\\\/uploads\\\/2024\\\/10\\\/image-570.png\",\"datePublished\":\"2024-10-18T06:36:55+00:00\",\"dateModified\":\"2024-10-28T12:11:08+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/knowledge-base\\\/configuring-dkim-and-spf-for-email-security\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/truehost.com\\\/support\\\/knowledge-base\\\/configuring-dkim-and-spf-for-email-security\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/knowledge-base\\\/configuring-dkim-and-spf-for-email-security\\\/#primaryimage\",\"url\":\"https:\\\/\\\/truehost.com\\\/support\\\/wp-content\\\/uploads\\\/2024\\\/10\\\/image-570.png\",\"contentUrl\":\"https:\\\/\\\/truehost.com\\\/support\\\/wp-content\\\/uploads\\\/2024\\\/10\\\/image-570.png\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/knowledge-base\\\/configuring-dkim-and-spf-for-email-security\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/truehost.com\\\/support\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Configuring DKIM and SPF for Email Security\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/#website\",\"url\":\"https:\\\/\\\/truehost.com\\\/support\\\/\",\"name\":\"\",\"description\":\"Help In a Click\",\"publisher\":{\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/truehost.com\\\/support\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/#organization\",\"name\":\"Truehost Kenya\",\"url\":\"https:\\\/\\\/truehost.com\\\/support\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/truehost.com\\\/support\\\/wp-content\\\/uploads\\\/2026\\\/04\\\/cropped-image_2026-04-16_174808866.png\",\"contentUrl\":\"https:\\\/\\\/truehost.com\\\/support\\\/wp-content\\\/uploads\\\/2026\\\/04\\\/cropped-image_2026-04-16_174808866.png\",\"width\":240,\"height\":48,\"caption\":\"Truehost Kenya\"},\"image\":{\"@id\":\"https:\\\/\\\/truehost.com\\\/support\\\/#\\\/schema\\\/logo\\\/image\\\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Configuring DKIM and SPF for Email Security -","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/","og_locale":"en_US","og_type":"article","og_title":"Configuring DKIM and SPF for Email Security -","og_description":"Configuring DomainKeys Identified Mail (DKIM) and Sender Policy Framework (SPF) is essential for improving email deliverability and preventing phishing or spoofing attacks. These protocols validate that emails are sent from trusted sources, thereby helping your emails avoid spam filters and maintain authenticity. Here\u2019s a comprehensive guide on configuring DKIM and SPF for robust email security. [&hellip;]","og_url":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/","article_modified_time":"2024-10-28T12:11:08+00:00","og_image":[{"url":"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570.png","type":"","width":"","height":""}],"twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/","url":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/","name":"Configuring DKIM and SPF for Email Security -","isPartOf":{"@id":"https:\/\/truehost.com\/support\/#website"},"primaryImageOfPage":{"@id":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/#primaryimage"},"image":{"@id":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/#primaryimage"},"thumbnailUrl":"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570.png","datePublished":"2024-10-18T06:36:55+00:00","dateModified":"2024-10-28T12:11:08+00:00","breadcrumb":{"@id":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/#primaryimage","url":"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570.png","contentUrl":"https:\/\/truehost.com\/support\/wp-content\/uploads\/2024\/10\/image-570.png"},{"@type":"BreadcrumbList","@id":"https:\/\/truehost.com\/support\/knowledge-base\/configuring-dkim-and-spf-for-email-security\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/truehost.com\/support\/"},{"@type":"ListItem","position":2,"name":"Configuring DKIM and SPF for Email Security"}]},{"@type":"WebSite","@id":"https:\/\/truehost.com\/support\/#website","url":"https:\/\/truehost.com\/support\/","name":"","description":"Help In a Click","publisher":{"@id":"https:\/\/truehost.com\/support\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/truehost.com\/support\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/truehost.com\/support\/#organization","name":"Truehost Kenya","url":"https:\/\/truehost.com\/support\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/truehost.com\/support\/#\/schema\/logo\/image\/","url":"https:\/\/truehost.com\/support\/wp-content\/uploads\/2026\/04\/cropped-image_2026-04-16_174808866.png","contentUrl":"https:\/\/truehost.com\/support\/wp-content\/uploads\/2026\/04\/cropped-image_2026-04-16_174808866.png","width":240,"height":48,"caption":"Truehost Kenya"},"image":{"@id":"https:\/\/truehost.com\/support\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/docs\/15406","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/types\/docs"}],"author":[{"embeddable":true,"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/comments?post=15406"}],"version-history":[{"count":22,"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/docs\/15406\/revisions"}],"predecessor-version":[{"id":15949,"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/docs\/15406\/revisions\/15949"}],"wp:attachment":[{"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/media?parent=15406"}],"wp:term":[{"taxonomy":"doc_category","embeddable":true,"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/doc_category?post=15406"},{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/truehost.com\/support\/wp-json\/wp\/v2\/doc_tag?post=15406"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}