{"id":417,"date":"2015-04-03T14:49:27","date_gmt":"2015-04-03T09:49:27","guid":{"rendered":"http:\/\/128.199.176.160\/?p=417"},"modified":"2025-09-11T17:42:10","modified_gmt":"2025-09-11T12:42:10","slug":"what-is-wordpress-nonce-and-how-it-works","status":"publish","type":"post","link":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/","title":{"rendered":"What is WordPress nonce and how it works?"},"content":{"rendered":"\n<p>Today, I am going to share with you a tip that\u00a0how we can make our <strong>WordPress plugins<\/strong> are themes more secure. I have seen in my plugins and themes where\u00a0WordPress developers are not using <strong>WordPress nonces<\/strong> even though it is\u00a0<strong>VERY<\/strong> important. If you are working as a WordPress freelancer developer\u00a0and\u00a0g custom plugins or themes, I am sure this article is going to be very helpful for you.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-what-actually-wordpress-nonce-nbsp-means\"><span style=\"text-decoration: underline;\">What actually WordPress nonce&nbsp;means?<\/span><\/h2>\n\n\n\n<p>WordPress Nonce basically in short is&nbsp;the term used for <strong>number used once<\/strong>. It&#8217;s a string value, a temporary unique key that is generated by WordPress automatically and acts as a special security token to check whether you are the same person who&#8217;s performing an action or someone else while submitting a form, adding a post, deleting a post, etc.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-why-we-should-use-wordpress-nonce\"><span style=\"text-decoration: underline;\">Why we should use WordPress nonce?<\/span><\/h2>\n\n\n\n<p>The main purpose of the nonce is to protect your site from malicious hacking attacks such as <strong>Cross-Site Request Forgery (CSRF)<\/strong> or sometimes pronounced <strong>sea-surf <\/strong>or<strong> XSRF<\/strong>, which is used to trick someone to submit a form or click on a link that will cause harm to your site.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-how-nonce-works-in-wordpress\"><span style=\"text-decoration: underline;\">How nonce works in WordPress?<\/span><\/h2>\n\n\n\n<p>It is very simple. As I mentioned earlier that it is generated by WordPress itself and when a form is submitted or a link is clicked, WordPress checks the nonce value and if it matches, you are free to proceed.<\/p>\n\n\n\n<p>A thing to remember, you don&#8217;t need to do anything about nonce in those forms or links which are generated by WordPress, like <strong>\u201cadd post\u201d, \u201cedit post\u201d<\/strong>, but&nbsp;you have to use&nbsp;nonce in your custom build plugins or themes you will create later.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-how-to-use-nonce-in-wordpress\"><span style=\"text-decoration: underline;\">How to use nonce in WordPress?<\/span><\/h2>\n\n\n\n<p>Before we walk you through a complete example of how to implement a nonce in a form or in a URL, lets us understand how the nonce works in WordPress.<\/p>\n\n\n\n<p>There are three steps that we must follow to implement a nonce in WordPress plugin or a theme:<\/p>\n\n\n\n<p>1. How to create a nonce.<br>\n2. How to pass a nonce through a Form or URL.<br>\n3. How to verify a nonce before doing a specific action.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"h-1-how-to-create-a-nonce\"><span style=\"text-decoration: underline;\">1. How to create a nonce?<\/span><\/h3>\n\n\n\n<p>To create a nonce, there is a function name &#8220;<strong>wp_create_nonce ($action)&#8221;<\/strong>, which generates and returns a unique value based on the current time and the $action.<br>\nThe <strong>&#8220;$action&#8221;<\/strong> parameter is optional but&nbsp;<b>recommended<\/b>, $action parameter refers to what will happen.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$nonce= wp_create_nonce('delete-post');<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"h-2-how-to-pass-a-nonce-through-a-form-or-url\"><span style=\"text-decoration: underline;\">2. How to pass a nonce through a Form or URL?<\/span><\/h3>\n\n\n\n<p>How to pass a nonce in URLs.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">&lt;a href=\"myplugin.php?_wpnonce=&lt;?php echo $nonce; ?&gt;\"&gt;<\/pre>\n\n\n\n<p>How to pass a nonce in Forms.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">&lt;form method=\"post\"&gt;&lt;?php wp_nonce_field( 'name_of_my_action', 'name_of_nonce_field' );?&gt;\n&lt;!-- some inputs here ... --&gt;   \n&lt;\/form&gt;<\/pre>\n\n\n\n<p>We use <strong>&#8220;wp_nonce_field($action,$name)&#8221;<\/strong>&nbsp;to pass a nonce through forms. <strong>wp_nonce_field()<\/strong> function will generate a hidden input field which stores a nonce value and can be retrieved later on.<\/p>\n\n\n\n<p>The parameter <strong>\u201cname_of_my_action\u201d<\/strong> is the context in which you are using the nonce field and<strong> \u201cname_of_nonce_field\u201d<\/strong> is any name you want to specify. Default is <strong>\u201c_wpnonce\u201d<\/strong>. It&#8217;s better to use $action and $name parameter for better security.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"h-3-how-to-verify-a-nonce\"><span style=\"text-decoration: underline;\">3. How to verify a nonce?<\/span><\/h3>\n\n\n\n<p>After putting it into the form you can get it like this:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">if ( isset( $_POST['name_of_nonce_field'] ) &amp;&amp;\nwp_verify_nonce( $_POST[\u2018name_of_nonce_field\u2019], \u2018name_of_my_action\u2019 ) ) {\n\n\/\/ process form data\n\n} else {\nprint \u2018Sorry, your nonce did not verify. It is a secure WordPress site. go get a coffee !!';\nexit;\n}<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-example\"><span style=\"text-decoration: underline;\">Example:<\/span><\/h2>\n\n\n\n<p>In this example, we are creating a form and an embedded nonce field in it. This form can be used for your contact page or anything you like for your site where you are taking inputs from users.<\/p>\n\n\n\n<p>The HTML code for the form is (notice the <strong>wp_nonce_field function<\/strong>):<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">&lt;form id=\"form\"&gt;\n&lt;?php wp_nonce_field( 'contact_form_submit', 'cform_generate_nonce' );?&gt;\n            &lt;label&gt;Name&lt;\/label&gt; &lt;input type=\"text\" name=\"name\" class=\"text\" id=\"name\"&gt;&lt;br&gt;\n            &lt;label&gt;Email&lt;\/label&gt; &lt;input type=\"email\" name=\"email\" class=\"text\" id=\"email\"&gt;&lt;br&gt;\n\n            &lt;label&gt;Subject&lt;\/label&gt; &lt;input type=\"text\" name=\"subject\" class=\"text\" id=\"subject\"&gt;&lt;br&gt;\n            &lt;label&gt;Message&lt;\/label&gt;&lt;textarea id=\"message\" class=\"textarea\" name=\"message\"&gt;&lt;\/textarea&gt;\n            &lt;input name=\"action\" type=\"hidden\" value=\"simple_contact_form_process\" \/&gt;\n            &lt;input type=\"submit\" name=\"submit_form\" class=\"button\" value=\"send Message\" id=\"sendmessage\"&gt;\n            &lt;div class=\"formmessage\"&gt;&lt;p&gt;&lt;\/p&gt;&lt;\/div&gt;\n        &lt;\/form&gt;<\/pre>\n\n\n\n<p>So, you have your contact form ready and now want to take the data from form inputs and process it. Form Inputs are the doors where&nbsp;mostly malicious attacks happen and hackers run anything they like. So, you should properly sanitize your inputs which are very important for your website security.<\/p>\n\n\n\n<p>Here is how you will verify nonce in your contact form.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">&lt;?php\n\nif(isset($_POST['submit_form'])) {\n  if(!wp_verify_nonce('cform_generate_nonce','contact_form_submit')){\n      wp_die('Our Site is protected!!');\n   }else{\n      \/\/ process here your contact form with proper sanitize inputs.\n  }\n}\n\n?&gt;<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-conclusion\"><span style=\"text-decoration: underline;\">Conclusion<\/span><\/h2>\n\n\n\n<p><a href=\"https:\/\/codex.wordpress.org\/WordPress_Nonces\"><strong>WordPress nonce<\/strong><\/a> is playing a very important role in WordPress security and I recommend it should be implemented in every WordPress plugin and theme, but I see many plugins and themes are not using it. If this article was helpful for you in any way I would love to hear your feedback.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today, I am going to share with you a tip that&nbsp;how we can make our WordPress plugins are themes more secure. I have seen in my plugins and themes where&nbsp;WordPress developers are not using WordPress nonces even though it is&nbsp;VERY important. If you are working as a WordPress freelancer developer&nbsp;and&nbsp;g custom plugins or themes, I [&hellip;]<\/p>\n","protected":false},"author":9268,"featured_media":1514,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_analytify_skip_tracking":false,"footnotes":""},"categories":[47],"tags":[42,45,43,23],"class_list":["post-417","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tips-and-tricks","tag-nonce","tag-security","tag-tips","tag-wordpress"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.4 (Yoast SEO v27.4) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>What is WordPress nonce and how it works - WPBrigade<\/title>\n<meta name=\"description\" content=\"WordPress Nonce basically in short is the term used for number used once. It&#039;s a string value, a temporary unique key which is generated by WordPress....\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"What is WordPress nonce and how it works?\" \/>\n<meta property=\"og:description\" content=\"WordPress Nonce basically in short is the term used for number used once. It&#039;s a string value, a temporary unique key which is generated by WordPress....\" \/>\n<meta property=\"og:url\" content=\"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/\" \/>\n<meta property=\"og:site_name\" content=\"WPBrigade\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/facebook.com\/WPBrigade\" \/>\n<meta property=\"article:published_time\" content=\"2015-04-03T09:49:27+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-09-11T12:42:10+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/wpbrigade.com\/wp-content\/uploads\/2015\/04\/plugin-activated.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"800\" \/>\n\t<meta property=\"og:image:height\" content=\"400\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Editorial Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@wpbrigade\" \/>\n<meta name=\"twitter:site\" content=\"@wpbrigade\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Editorial Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/\"},\"author\":{\"name\":\"Editorial Team\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#\\\/schema\\\/person\\\/2dea64860327e163e768333724338de6\"},\"headline\":\"What is WordPress nonce and how it works?\",\"datePublished\":\"2015-04-03T09:49:27+00:00\",\"dateModified\":\"2025-09-11T12:42:10+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/\"},\"wordCount\":711,\"commentCount\":3,\"publisher\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/wpbrigade.com\\\/wp-content\\\/uploads\\\/2015\\\/04\\\/plugin-activated.jpg\",\"keywords\":[\"nonce\",\"Security\",\"tips\",\"WordPress\"],\"articleSection\":[\"Tips and Tricks\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/\",\"url\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/\",\"name\":\"What is WordPress nonce and how it works - WPBrigade\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/wpbrigade.com\\\/wp-content\\\/uploads\\\/2015\\\/04\\\/plugin-activated.jpg\",\"datePublished\":\"2015-04-03T09:49:27+00:00\",\"dateModified\":\"2025-09-11T12:42:10+00:00\",\"description\":\"WordPress Nonce basically in short is the term used for number used once. It's a string value, a temporary unique key which is generated by WordPress....\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/#primaryimage\",\"url\":\"https:\\\/\\\/wpbrigade.com\\\/wp-content\\\/uploads\\\/2015\\\/04\\\/plugin-activated.jpg\",\"contentUrl\":\"https:\\\/\\\/wpbrigade.com\\\/wp-content\\\/uploads\\\/2015\\\/04\\\/plugin-activated.jpg\",\"width\":800,\"height\":400,\"caption\":\"WordPress nonce\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/what-is-wordpress-nonce-and-how-it-works\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/wpbrigade.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"What is WordPress nonce and how it works?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#website\",\"url\":\"https:\\\/\\\/wpbrigade.com\\\/\",\"name\":\"WPBrigade\",\"description\":\"WordPress Development Agency\",\"publisher\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/wpbrigade.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#organization\",\"name\":\"WPBrigade\",\"url\":\"https:\\\/\\\/wpbrigade.com\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/wpbrigade.com\\\/wp-content\\\/uploads\\\/2021\\\/07\\\/Screen-Shot-2021-07-02-at-12.42.14-AM.png\",\"contentUrl\":\"https:\\\/\\\/wpbrigade.com\\\/wp-content\\\/uploads\\\/2021\\\/07\\\/Screen-Shot-2021-07-02-at-12.42.14-AM.png\",\"width\":271,\"height\":63,\"caption\":\"WPBrigade\"},\"image\":{\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/facebook.com\\\/WPBrigade\",\"https:\\\/\\\/x.com\\\/wpbrigade\",\"https:\\\/\\\/www.instagram.com\\\/wpbrigade.agency\\\/\",\"https:\\\/\\\/www.linkedin.com\\\/company\\\/wpbrigade\",\"https:\\\/\\\/www.youtube.com\\\/c\\\/Wpbrigade\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/wpbrigade.com\\\/#\\\/schema\\\/person\\\/2dea64860327e163e768333724338de6\",\"name\":\"Editorial Team\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1bba47142d1af61a55ed7e262cdf830010cbef95f98003b6526c9b1e6a8e4f32?s=96&d=retro&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1bba47142d1af61a55ed7e262cdf830010cbef95f98003b6526c9b1e6a8e4f32?s=96&d=retro&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1bba47142d1af61a55ed7e262cdf830010cbef95f98003b6526c9b1e6a8e4f32?s=96&d=retro&r=g\",\"caption\":\"Editorial Team\"},\"sameAs\":[\"https:\\\/\\\/wpbrigade.com\\\/\"]}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"What is WordPress nonce and how it works - WPBrigade","description":"WordPress Nonce basically in short is the term used for number used once. It's a string value, a temporary unique key which is generated by WordPress....","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:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/","og_locale":"en_US","og_type":"article","og_title":"What is WordPress nonce and how it works?","og_description":"WordPress Nonce basically in short is the term used for number used once. It's a string value, a temporary unique key which is generated by WordPress....","og_url":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/","og_site_name":"WPBrigade","article_publisher":"https:\/\/facebook.com\/WPBrigade","article_published_time":"2015-04-03T09:49:27+00:00","article_modified_time":"2025-09-11T12:42:10+00:00","og_image":[{"width":800,"height":400,"url":"https:\/\/wpbrigade.com\/wp-content\/uploads\/2015\/04\/plugin-activated.jpg","type":"image\/jpeg"}],"author":"Editorial Team","twitter_card":"summary_large_image","twitter_creator":"@wpbrigade","twitter_site":"@wpbrigade","twitter_misc":{"Written by":"Editorial Team","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/#article","isPartOf":{"@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/"},"author":{"name":"Editorial Team","@id":"https:\/\/wpbrigade.com\/#\/schema\/person\/2dea64860327e163e768333724338de6"},"headline":"What is WordPress nonce and how it works?","datePublished":"2015-04-03T09:49:27+00:00","dateModified":"2025-09-11T12:42:10+00:00","mainEntityOfPage":{"@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/"},"wordCount":711,"commentCount":3,"publisher":{"@id":"https:\/\/wpbrigade.com\/#organization"},"image":{"@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/#primaryimage"},"thumbnailUrl":"https:\/\/wpbrigade.com\/wp-content\/uploads\/2015\/04\/plugin-activated.jpg","keywords":["nonce","Security","tips","WordPress"],"articleSection":["Tips and Tricks"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/","url":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/","name":"What is WordPress nonce and how it works - WPBrigade","isPartOf":{"@id":"https:\/\/wpbrigade.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/#primaryimage"},"image":{"@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/#primaryimage"},"thumbnailUrl":"https:\/\/wpbrigade.com\/wp-content\/uploads\/2015\/04\/plugin-activated.jpg","datePublished":"2015-04-03T09:49:27+00:00","dateModified":"2025-09-11T12:42:10+00:00","description":"WordPress Nonce basically in short is the term used for number used once. It's a string value, a temporary unique key which is generated by WordPress....","breadcrumb":{"@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/#primaryimage","url":"https:\/\/wpbrigade.com\/wp-content\/uploads\/2015\/04\/plugin-activated.jpg","contentUrl":"https:\/\/wpbrigade.com\/wp-content\/uploads\/2015\/04\/plugin-activated.jpg","width":800,"height":400,"caption":"WordPress nonce"},{"@type":"BreadcrumbList","@id":"https:\/\/wpbrigade.com\/what-is-wordpress-nonce-and-how-it-works\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/wpbrigade.com\/"},{"@type":"ListItem","position":2,"name":"What is WordPress nonce and how it works?"}]},{"@type":"WebSite","@id":"https:\/\/wpbrigade.com\/#website","url":"https:\/\/wpbrigade.com\/","name":"WPBrigade","description":"WordPress Development Agency","publisher":{"@id":"https:\/\/wpbrigade.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/wpbrigade.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/wpbrigade.com\/#organization","name":"WPBrigade","url":"https:\/\/wpbrigade.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wpbrigade.com\/#\/schema\/logo\/image\/","url":"https:\/\/wpbrigade.com\/wp-content\/uploads\/2021\/07\/Screen-Shot-2021-07-02-at-12.42.14-AM.png","contentUrl":"https:\/\/wpbrigade.com\/wp-content\/uploads\/2021\/07\/Screen-Shot-2021-07-02-at-12.42.14-AM.png","width":271,"height":63,"caption":"WPBrigade"},"image":{"@id":"https:\/\/wpbrigade.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/facebook.com\/WPBrigade","https:\/\/x.com\/wpbrigade","https:\/\/www.instagram.com\/wpbrigade.agency\/","https:\/\/www.linkedin.com\/company\/wpbrigade","https:\/\/www.youtube.com\/c\/Wpbrigade"]},{"@type":"Person","@id":"https:\/\/wpbrigade.com\/#\/schema\/person\/2dea64860327e163e768333724338de6","name":"Editorial Team","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/1bba47142d1af61a55ed7e262cdf830010cbef95f98003b6526c9b1e6a8e4f32?s=96&d=retro&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/1bba47142d1af61a55ed7e262cdf830010cbef95f98003b6526c9b1e6a8e4f32?s=96&d=retro&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1bba47142d1af61a55ed7e262cdf830010cbef95f98003b6526c9b1e6a8e4f32?s=96&d=retro&r=g","caption":"Editorial Team"},"sameAs":["https:\/\/wpbrigade.com\/"]}]}},"_links":{"self":[{"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/posts\/417","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/users\/9268"}],"replies":[{"embeddable":true,"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/comments?post=417"}],"version-history":[{"count":1,"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/posts\/417\/revisions"}],"predecessor-version":[{"id":317488,"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/posts\/417\/revisions\/317488"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/media\/1514"}],"wp:attachment":[{"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/media?parent=417"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/categories?post=417"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wpbrigade.com\/wpb-api\/wp\/v2\/tags?post=417"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}