{"id":1345,"date":"2021-07-23T07:21:44","date_gmt":"2021-07-23T12:21:44","guid":{"rendered":"https:\/\/www.knownhost.com\/kb\/?p=1345"},"modified":"2023-03-10T12:40:35","modified_gmt":"2023-03-10T18:40:35","slug":"what-cookies-are-set-with-wordpress-comments","status":"publish","type":"post","link":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/","title":{"rendered":"What Cookies are Set with WordPress Comments?"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 ez-toc-wrap-right counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #212121;color:#212121\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #212121;color:#212121\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 eztoc-toggle-hide-by-default' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/#how_are_wordpress_comments_cookies_used_for_anti-spam_protection\" >How are WordPress Comments Cookies Used for Anti-Spam Protection?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/#conclusion\" >Conclusion<\/a><\/li><\/ul><\/nav><\/div>\n\n<p>When someone visits your WordPress comments section, they become commenters. As a commenter, a visitor will get 3 distinct cookies set on their local machine so that with each WordPress comment they don\u2019t have to re-enter their name, email and\u00a0URL\u00a0over and over again. The 3 cookies are:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>comment_author_{HASH}<\/li>\n\n\n\n<li>comment_author_email_{HASH}<\/li>\n\n\n\n<li>comment_author_url_{HASH}<\/li>\n<\/ul>\n\n\n\n<p>By default, WordPress comments cookies should last for slightly under one year from when they were set, or until the commenter clears them off their local machine.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"how_are_commenter_cookies_used_for_anti-spam_protection\"><span class=\"ez-toc-section\" id=\"how_are_wordpress_comments_cookies_used_for_anti-spam_protection\"><\/span>How are WordPress Comments Cookies Used for Anti-Spam Protection?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>The general flow for  WordPress comments cookies and spam protection is:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Person, or bot, arrives on post&nbsp;URL<\/li>\n\n\n\n<li>Cookie is dropped<\/li>\n\n\n\n<li>Comment is submitted<\/li>\n<\/ol>\n\n\n\n<p>A savvy anti-spam plugin (that can be quite simple really) can check that a browser is humanoid, rather than spam AI, by dropping the cookie and checking to see if it is saved on the local machine [scenario 1].<\/p>\n\n\n\n<p>In instances where the AI is more than just the simplest of scripts, cookies will be saved and returned upon request, defeating any checks for existence. The basic cookie test is just not enough to defeat most spambots.<\/p>\n\n\n\n<p>In scenario 2, the time a cookie is dropped is compared to the time a comment is submitted. Allowing for speedy humans as a best case scenario, the server will diff the two times and compare to a speedy human. In other words, if somehow a name, email,&nbsp;URL&nbsp;and comment text is all submitted faster than a speedy human could possibly do it, it\u2019s obviously a spambot just dumping text as fast as it can.<\/p>\n\n\n\n<p>The only way a spambot can defeat the time measures of scenario 2 is to delay arrival on page and submitting of form fields. While there are some that can overcome this &#8211; it\u2019s very, very few.<\/p>\n\n\n\n<p>So how do you implement commenter cookie checking to stop spambots?<\/p>\n\n\n\n<p>Install the Cookies for Comments plugin using our <a href=\"https:\/\/wordpress.org\/plugins\/cookies-for-comments\/\">How to Install Plugins procedure here<\/a>.<\/p>\n\n\n\n<p>Be sure to clear cache (browser, WP plugins and hosting) before testing. However, as a human, you should be able to comment as normal, without feeling any odd pains or inconveniences, while spambots are not.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"conclusion\"><\/span>Conclusion<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Have a WordPress website? Check out our <a href=\"https:\/\/www.knownhost.com\/wordpress-hosting\"><strong>Managed Hosting for WordPress<\/strong><\/a> and see if we are a good fit for you. <strong><a href=\"https:\/\/www.knownhost.com\">KnownHost <\/a><\/strong>offers 365 days a year, 24 hours a day, all 7 days of the week best in class technical support. A dedicated team ready to help you should you need our assistance. You\u2019re not using KnownHost for the best webhosting experience? Well, why not?<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When someone visits your WordPress comments section, they become commenters. As a commenter, a visitor will get 3 distinct cookies set on their local machine so that with each WordPress comment they don\u2019t have to re-enter their name, email and\u00a0URL\u00a0over and over again. The 3 cookies are: By default, WordPress comments cookies should last for [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[146],"tags":[251,252,106],"class_list":["post-1345","post","type-post","status-publish","format-standard","hentry","category-wordpress","tag-blogs","tag-cms","tag-wordpress"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>What Cookies are Set with WordPress Comments? - KnownHost<\/title>\n<meta name=\"description\" content=\"Learn about WordPress comments and what cookies are set when you activate the comments on your premium website.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"What Cookies are Set with WordPress Comments? - KnownHost\" \/>\n<meta property=\"og:description\" content=\"Learn about WordPress comments and what cookies are set when you activate the comments on your premium website.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/\" \/>\n<meta property=\"og:site_name\" content=\"KnownHost\" \/>\n<meta property=\"article:published_time\" content=\"2021-07-23T12:21:44+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-03-10T18:40:35+00:00\" \/>\n<meta name=\"author\" content=\"Jonathan K. W.\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jonathan K. W.\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/what-cookies-are-set-with-wordpress-comments\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/what-cookies-are-set-with-wordpress-comments\\\/\"},\"author\":{\"name\":\"Jonathan K. W.\",\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/#\\\/schema\\\/person\\\/3db6e20d1f33519cd68fe0ba1230a48b\"},\"headline\":\"What Cookies are Set with WordPress Comments?\",\"datePublished\":\"2021-07-23T12:21:44+00:00\",\"dateModified\":\"2023-03-10T18:40:35+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/what-cookies-are-set-with-wordpress-comments\\\/\"},\"wordCount\":443,\"keywords\":[\"blogs\",\"cms\",\"wordpress\"],\"articleSection\":[\"WordPress\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/what-cookies-are-set-with-wordpress-comments\\\/\",\"url\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/what-cookies-are-set-with-wordpress-comments\\\/\",\"name\":\"What Cookies are Set with WordPress Comments? - KnownHost\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/#website\"},\"datePublished\":\"2021-07-23T12:21:44+00:00\",\"dateModified\":\"2023-03-10T18:40:35+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/#\\\/schema\\\/person\\\/3db6e20d1f33519cd68fe0ba1230a48b\"},\"description\":\"Learn about WordPress comments and what cookies are set when you activate the comments on your premium website.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/what-cookies-are-set-with-wordpress-comments\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/what-cookies-are-set-with-wordpress-comments\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/what-cookies-are-set-with-wordpress-comments\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"What Cookies are Set with WordPress Comments?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/#website\",\"url\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/\",\"name\":\"KnownHost\",\"description\":\"KnownHost provides a comprehensive webhosting knowledge base to help answer many of your common webhosting and linux questions.\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.knownhost.com\\\/kb\\\/#\\\/schema\\\/person\\\/3db6e20d1f33519cd68fe0ba1230a48b\",\"name\":\"Jonathan K. W.\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f432b99e6651fe8d1deb57a285bd84e806f1c9ae8b4c6c585d7e3a0b33789ad9?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f432b99e6651fe8d1deb57a285bd84e806f1c9ae8b4c6c585d7e3a0b33789ad9?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f432b99e6651fe8d1deb57a285bd84e806f1c9ae8b4c6c585d7e3a0b33789ad9?s=96&d=mm&r=g\",\"caption\":\"Jonathan K. W.\"},\"sameAs\":[\"https:\\\/\\\/www.knownhost.com\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"What Cookies are Set with WordPress Comments? - KnownHost","description":"Learn about WordPress comments and what cookies are set when you activate the comments on your premium website.","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:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/","og_locale":"en_US","og_type":"article","og_title":"What Cookies are Set with WordPress Comments? - KnownHost","og_description":"Learn about WordPress comments and what cookies are set when you activate the comments on your premium website.","og_url":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/","og_site_name":"KnownHost","article_published_time":"2021-07-23T12:21:44+00:00","article_modified_time":"2023-03-10T18:40:35+00:00","author":"Jonathan K. W.","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Jonathan K. W.","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/#article","isPartOf":{"@id":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/"},"author":{"name":"Jonathan K. W.","@id":"https:\/\/www.knownhost.com\/kb\/#\/schema\/person\/3db6e20d1f33519cd68fe0ba1230a48b"},"headline":"What Cookies are Set with WordPress Comments?","datePublished":"2021-07-23T12:21:44+00:00","dateModified":"2023-03-10T18:40:35+00:00","mainEntityOfPage":{"@id":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/"},"wordCount":443,"keywords":["blogs","cms","wordpress"],"articleSection":["WordPress"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/","url":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/","name":"What Cookies are Set with WordPress Comments? - KnownHost","isPartOf":{"@id":"https:\/\/www.knownhost.com\/kb\/#website"},"datePublished":"2021-07-23T12:21:44+00:00","dateModified":"2023-03-10T18:40:35+00:00","author":{"@id":"https:\/\/www.knownhost.com\/kb\/#\/schema\/person\/3db6e20d1f33519cd68fe0ba1230a48b"},"description":"Learn about WordPress comments and what cookies are set when you activate the comments on your premium website.","breadcrumb":{"@id":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.knownhost.com\/kb\/what-cookies-are-set-with-wordpress-comments\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.knownhost.com\/kb\/"},{"@type":"ListItem","position":2,"name":"What Cookies are Set with WordPress Comments?"}]},{"@type":"WebSite","@id":"https:\/\/www.knownhost.com\/kb\/#website","url":"https:\/\/www.knownhost.com\/kb\/","name":"KnownHost","description":"KnownHost provides a comprehensive webhosting knowledge base to help answer many of your common webhosting and linux questions.","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.knownhost.com\/kb\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.knownhost.com\/kb\/#\/schema\/person\/3db6e20d1f33519cd68fe0ba1230a48b","name":"Jonathan K. W.","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/f432b99e6651fe8d1deb57a285bd84e806f1c9ae8b4c6c585d7e3a0b33789ad9?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/f432b99e6651fe8d1deb57a285bd84e806f1c9ae8b4c6c585d7e3a0b33789ad9?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/f432b99e6651fe8d1deb57a285bd84e806f1c9ae8b4c6c585d7e3a0b33789ad9?s=96&d=mm&r=g","caption":"Jonathan K. W."},"sameAs":["https:\/\/www.knownhost.com"]}]}},"_links":{"self":[{"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/posts\/1345","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/comments?post=1345"}],"version-history":[{"count":0,"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/posts\/1345\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/media?parent=1345"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/categories?post=1345"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.knownhost.com\/kb\/wp-json\/wp\/v2\/tags?post=1345"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}