{"id":23220,"date":"2024-08-30T10:42:35","date_gmt":"2024-08-30T10:42:35","guid":{"rendered":"https:\/\/kwebby.com\/blog\/?p=23220"},"modified":"2024-08-30T10:43:08","modified_gmt":"2024-08-30T10:43:08","slug":"what-is-x-robots-tag-how-and-when-to-use","status":"publish","type":"post","link":"https:\/\/kwebby.com\/blog\/what-is-x-robots-tag-how-and-when-to-use\/","title":{"rendered":"What is X-Robots-Tag? How and When to Use?"},"content":{"rendered":"\n<p>In the digital marketing world, controlling your website\u2019s visibility to search engines is key. Enter the<a href=\"https:\/\/developers.google.com\/search\/docs\/crawling-indexing\/robots-meta-tag#xrobotstag\" data-type=\"link\" data-id=\"https:\/\/developers.google.com\/search\/docs\/crawling-indexing\/robots-meta-tag#xrobotstag\" target=\"_blank\" rel=\"noreferrer noopener\"> X-Robots-Tag<\/a>, a powerful but often overlooked tool to fine-tune how your content interacts with <a href=\"https:\/\/kwebby.com\/blog\/optimizing-crawling-with-if-modified-since-headers\/\" data-type=\"post\" data-id=\"23081\">search engine crawlers<\/a>.<\/p>\n\n\n\n<p>Whether you want to stop certain pages from being indexed or tell search engines how to handle your content, the X-Robots-Tag is your new best friend for optimising your online presence.<\/p>\n\n\n\n<p>In this post, we\u2019ll go into what the X-Robots-Tag is, how it works and best practices for using it so you can get the most out of your website\u2019s SEO.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">What is the X-Robots-Tag?<\/h2>\n\n\n\n<p>The X-Robots-Tag might sound technical but it\u2019s a simple yet powerful tool to optimise your website\u2019s SEO. It\u2019s an optional part of the <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Glossary\/Response_header\" data-type=\"link\" data-id=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Glossary\/Response_header\" target=\"_blank\" rel=\"noreferrer noopener\">HTTP response header<\/a> that tells search engines how to crawl and index your web pages.<\/p>\n\n\n\n<p>Unlike the robots meta tag which can only be applied to HTML pages the X-Robots-Tag can be applied to non-HTML files including images, text files and PDFs. So you can manage the visibility of different content types with ease.<\/p>\n\n\n\n<p>For example if you have a PDF document with sensitive information that shouldn\u2019t be in search results you can use the X-Robots-Tag in the HTTP response to tell search engines not to index it. Imagine your server responding with something like this:<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"HTTP\/1.1 200 OK\nDate: Tue, 30 Aug 2024 11:38:17 GMT\nContent-encoding: gzip\nX-Robots-Tag: noindex\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9\">HTTP<\/span><span style=\"color: #81A1C1\">\/<\/span><span style=\"color: #B48EAD\">1.1<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">200<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">OK<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">Date<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">Tue<\/span><span style=\"color: #ECEFF4\">,<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">30<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">Aug<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">2024<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">11<\/span><span style=\"color: #D8DEE9FF\">:<\/span><span style=\"color: #B48EAD\">38<\/span><span style=\"color: #D8DEE9FF\">:<\/span><span style=\"color: #B48EAD\">17<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">GMT<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9\">Content<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">encoding<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">gzip<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">noindex<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>This lets you control not just how your website pages are indexed but also how external files are treated by search crawlers so you have a more comprehensive approach to managing your online presence. You can even specify directives for specific user agents as in this example:<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"HTTP\/1.1 200 OK\nDate: Tue, 30 Aug 2024 11:38:17 GMT\nContent-encoding: gzip\nX-Robots-Tag: googlebot: noarchive, nofollow\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9\">HTTP<\/span><span style=\"color: #81A1C1\">\/<\/span><span style=\"color: #B48EAD\">1.1<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">200<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">OK<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">Date<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">Tue<\/span><span style=\"color: #ECEFF4\">,<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">30<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">Aug<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">2024<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">11<\/span><span style=\"color: #D8DEE9FF\">:<\/span><span style=\"color: #B48EAD\">38<\/span><span style=\"color: #D8DEE9FF\">:<\/span><span style=\"color: #B48EAD\">17<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">GMT<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9\">Content<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">encoding<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">gzip<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> googlebot<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">noarchive<\/span><span style=\"color: #ECEFF4\">,<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">nofollow<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>By using the X-Robots-Tag you get an extra layer of control that can really help your digital presence.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">X-Robots-Tags Derivatives<\/h2>\n\n\n\n<p>As we get into the X-Robots-Tag more we need to understand its derivatives. Google\u2019s specifications say that any directive used in a robots meta tag can also be used as an X-Robots-Tag. While the full list of valid indexing and serving directives is long the most common ones are:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>noindex<\/strong>: This tells search engines not to show the page, file or media in search results. For example:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"  X-Robots-Tag: noindex\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">  <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">noindex<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>nofollow<\/strong>: When this is used it tells search engine crawlers not to follow the links on the page or document. For example:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"  X-Robots-Tag: nofollow\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">  <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">nofollow<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>none<\/strong>: This is like a combination of \u201cnoindex, nofollow\u201d so it restricts visibility and link following. Example:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"  X-Robots-Tag: none\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">  <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">none<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>noarchive<\/strong>: By using this directive you prevent search engines from showing a cached version of the page in their results. Example:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"  X-Robots-Tag: noarchive\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">  <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">noarchive<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>nosnippet<\/strong>: This tells search engines not to show a snippet or preview of the page in search results so you can keep the element of surprise for the user. For example:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"  X-Robots-Tag: nosnippet\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">  <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">nosnippet<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>Use these directives wisely. For the full list of directives accepted by Google for example, notranslate, noimageindex check their <a href=\"https:\/\/developers.google.com\/search\/docs\/crawling-indexing\/robots-meta-tag#directives\" target=\"_blank\" data-type=\"link\" data-id=\"https:\/\/developers.google.com\/search\/docs\/crawling-indexing\/robots-meta-tag#directives\" rel=\"noreferrer noopener\">documentation<\/a>. By using these you can keep your website intact and visible as per your strategy.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Where to Add X-robots-tag<\/h2>\n\n\n\n<p>To use the X-Robots-Tag on your website you need to put it in the right configuration files depending on the server you\u2019re using. Below are step by step instructions for both Apache and Nginx servers so you can optimize your website visibility easily.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Apache Server (htaccess)<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Access Your Server\u2019s Files<\/strong>: Use an FTP client or your web hosting provider\u2019s file manager to connect to your server.<\/li>\n\n\n\n<li><strong>Locate the .htaccess File:<\/strong> Go to the root directory of your website. This is usually the public_html or www folder. Look for the<a href=\"https:\/\/kwebby.com\/htaccess-redirect-generator\" target=\"_blank\" data-type=\"link\" data-id=\"https:\/\/kwebby.com\/htaccess-redirect-generator\" rel=\"noreferrer noopener\"> .htaccess file<\/a>. If it doesn\u2019t exist you can create one using a text editor.<\/li>\n\n\n\n<li><strong>Edit the .htaccess File<\/strong>: Open the .htaccess file for editing. You can use any text editor you like, Notepad or TextEdit.<\/li>\n\n\n\n<li><strong>Add X-Robots-Tag Directive<\/strong>: Put the X-Robots-Tag directive in the file. Here\u2019s an example that tells search engines not to index all files in the \/private-files\/ directory:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"   &lt;Directory &quot;\/home\/username\/public_html\/private-files&quot;&gt;\n       Header set X-Robots-Tag &quot;noindex&quot;\n   &lt;\/Directory&gt;\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #81A1C1\">&lt;<\/span><span style=\"color: #8FBCBB\">Directory<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #ECEFF4\">&quot;<\/span><span style=\"color: #A3BE8C\">\/home\/username\/public_html\/private-files<\/span><span style=\"color: #ECEFF4\">&quot;<\/span><span style=\"color: #81A1C1\">&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">       Header set X-Robots-Tag &quot;noindex&quot;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #81A1C1\">&lt;\/<\/span><span style=\"color: #8FBCBB\">Directory<\/span><span style=\"color: #81A1C1\">&gt;<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Save<\/strong>: After adding your directives save the file and close the editor.<\/li>\n\n\n\n<li><strong>Test<\/strong>: To check if the tag is working use an online tool or the browser\u2019s developer console to check the HTTP response header of your page.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">Nginx Server (nginx.conf)<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Access Your Server\u2019s Configuration<\/strong>: Use SSH or your control panel to access your <a href=\"https:\/\/kwebby.com\/nginx-redirect-generator\" target=\"_blank\" data-type=\"link\" data-id=\"https:\/\/kwebby.com\/nginx-redirect-generator\" rel=\"noreferrer noopener\">Nginx <\/a>server configuration file, usually named nginx.conf.<\/li>\n\n\n\n<li><strong>Backup Your Configuration File<\/strong>: Before you make any changes backup the original nginx.conf file. This will allow you to restore the previous configuration if something goes wrong.<\/li>\n\n\n\n<li><strong>Edit the nginx.conf File<\/strong>: Open the nginx.conf file with a text editor. You may need superuser (root) privileges to edit this file.<\/li>\n\n\n\n<li><strong>Set the X-Robots-Tag Directive<\/strong>: Add the following in the server block to prevent all search engines from indexing the \/private-files\/ directory:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"   location \/private-files\/ {\n       add_header X-Robots-Tag &quot;noindex&quot;;\n   }\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #D8DEE9\">location<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #81A1C1\">\/<\/span><span style=\"color: #D8DEE9\">private<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">files<\/span><span style=\"color: #81A1C1\">\/<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #ECEFF4\">{<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">       <\/span><span style=\"color: #D8DEE9\">add_header<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Tag<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #ECEFF4\">&quot;<\/span><span style=\"color: #A3BE8C\">noindex<\/span><span style=\"color: #ECEFF4\">&quot;<\/span><span style=\"color: #81A1C1\">;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #ECEFF4\">}<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Save and Exit<\/strong>: After adding your directive save and exit the editor.<\/li>\n\n\n\n<li><strong>Test<\/strong>: To make sure your directives work reload Nginx with sudo nginx -s reload. Then test the implementation by checking the HTTP response headers of any files within the location.<\/li>\n<\/ul>\n\n\n\n<p>By following these steps for either <a href=\"https:\/\/www.apache.org\/\" target=\"_blank\" data-type=\"link\" data-id=\"https:\/\/www.apache.org\/\" rel=\"noreferrer noopener\">Apache<\/a> or <a href=\"https:\/\/kwebby.com\/blog\/nginx-vs-apache-web-server\/\" data-type=\"post\" data-id=\"13689\">Nginx<\/a>, you\u2019ve added the X-Robots-Tag to your server configuration. Now you have more control over how search engines interact with your content and your website\u2019s SEO.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How do I find my X-robots-tag for my webpage?<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"374\" src=\"https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-04-25-1024x374.png\" alt=\"\" class=\"wp-image-23221\" title=\"\" srcset=\"https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-04-25-1024x374.png 1024w, https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-04-25-300x110.png 300w, https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-04-25-768x280.png 768w, https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-04-25-1536x561.png 1536w, https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-04-25-2048x748.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>To check the X-Robots-Tag for a specific webpage you need to dive into the HTTP response headers, this tag is not part of the HTML markup. It might seem a bit complex at first but with a few simple steps you\u2019ll be able to find it. Here\u2019s how you can view the HTTP response headers in Google Chrome:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Load the Page<\/strong>: Enter the URL of the webpage you want to inspect into Google Chrome.<\/li>\n\n\n\n<li><strong>Open Developer Tools<\/strong>: Right-click anywhere on the page and select \u201cInspect\u201d to open the developer tools.<\/li>\n\n\n\n<li><strong>Select the Network Tab<\/strong>: Go to the \u201cNetwork\u201d tab in the developer tools.<\/li>\n\n\n\n<li><strong>Reload the Page<\/strong>: Refresh the page to gather network data. This will populate the Network panel with all the files and resources loaded by the page.<\/li>\n\n\n\n<li><strong>Choose the File<\/strong>: Select the file from the list on the left side of the panel.<\/li>\n\n\n\n<li><strong>View HTTP Headers<\/strong>: Once the file is selected you\u2019ll see the HTTP headers information on the right side of the panel. Here you can find the X-Robots-Tag if it\u2019s set.<\/li>\n<\/ul>\n\n\n\n<p>By following these steps you can check the X-Robots-Tag for any webpage and know how search engines are being told to index or not index your content.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">X-Robots-tag vs Robots Meta Tag<\/h2>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th><strong>Feature<\/strong><\/th><th><strong>Robots Meta Tag<\/strong><\/th><th><strong>X-Robots-Tag<\/strong><\/th><\/tr><\/thead><tbody><tr><td><strong>Usage<\/strong><\/td><td>Inserted within the <code>&lt;head&gt;<\/code> section of an HTML page.<\/td><td>Included in the HTTP response header.<\/td><\/tr><tr><td><strong>Content Control<\/strong><\/td><td>Controls how individual pages are indexed and served by search engines.<\/td><td>Controls indexing of various resources, including non-HTML files like PDFs, images, and videos.<\/td><\/tr><tr><td><strong>Customization<\/strong><\/td><td>Allows targeting specific crawlers using user agent tokens (e.g., <code>googlebot<\/code>, <code>googlebot-news<\/code>).<\/td><td>Allows setting rules for specific crawlers by specifying user agents in the HTTP header.<\/td><\/tr><tr><td><strong>Example<\/strong><\/td><td><code>&lt;meta name=\"robots\" content=\"noindex\"&gt;<\/code><\/td><td><code>X-Robots-Tag: noindex<\/code><\/td><\/tr><tr><td><strong>CMS Compatibility<\/strong><\/td><td>May require CMS customization or search engine settings page to insert meta tags.<\/td><td>Applied via server configuration, making it suitable for resources where direct HTML modification isn\u2019t possible.<\/td><\/tr><tr><td><strong>Case Sensitivity<\/strong><\/td><td>Both the <code>name<\/code> and <code>content<\/code> attributes are case-insensitive.<\/td><td>The header, user agent name, and specified values are not case-sensitive.<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Examples of X-Robots-Tag<\/h3>\n\n\n\n<p>Here are a few scenarios where the X-Robots-Tag is better than the robots meta tag for managing content:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Blocking Non-HTML Resources<\/strong>: Suppose you have a PDF document with sensitive information you don\u2019t want search engines to index. With the X-Robots-Tag you can prevent this PDF from showing up in search results by adding the following HTTP header response:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"   HTTP\/1.1 200 OK\n   X-Robots-Tag: noindex\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #D8DEE9\">HTTP<\/span><span style=\"color: #81A1C1\">\/<\/span><span style=\"color: #B48EAD\">1.1<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">200<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">OK<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">noindex<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>This will make search engines respect your wishes even for file types that don\u2019t allow meta tags.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Controlling Access for Different Crawlers<\/strong>: If you want to block indexing for the images on your site for one crawler but allow another to see them, the X-Robots-Tag allows you to target based on user agents. For example:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"   HTTP\/1.1 200 OK\n   X-Robots-Tag: googlebot: noindex\n   X-Robots-Tag: bingbot: index\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #D8DEE9\">HTTP<\/span><span style=\"color: #81A1C1\">\/<\/span><span style=\"color: #B48EAD\">1.1<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">200<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">OK<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> googlebot<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">noindex<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> bingbot<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">index<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>This is flexibility the meta tag can\u2019t offer.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Combining Multiple Directives<\/strong>: Often you need to manage content visibility with multiple directives at once. The X-Robots-Tag can do this easily. For example if you want to block indexing and also tell search engines not to archive the content you could use:<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"   HTTP\/1.1 200 OK\n   X-Robots-Tag: noindex, noarchive\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #D8DEE9\">HTTP<\/span><span style=\"color: #81A1C1\">\/<\/span><span style=\"color: #B48EAD\">1.1<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #B48EAD\">200<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">OK<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D8DEE9FF\">   <\/span><span style=\"color: #D8DEE9\">X<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">Robots<\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9FF\">Tag<\/span><span style=\"color: #ECEFF4\">:<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">noindex<\/span><span style=\"color: #ECEFF4\">,<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">noarchive<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>This ability to combine content instructions in one header makes the X-Robots-Tag a must have in any webmaster\u2019s SEO toolbox.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Google Answers: Is It \u201cOK\u201d to miss X-robots-tag on your website<\/h2>\n\n\n\n<iframe loading=\"lazy\" width=\"560\" height=\"315\" src=\"https:\/\/www.youtube.com\/embed\/Fj42gKDQxYI?si=SS5jyEOHPr7wMMKp&amp;start=910\" title=\"YouTube video player\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe>\n\n\n\n<p>In a recent SEO Office Hours session, Google\u2019s John Mueller answered a common question about the X-Robots-Tag. Eric Richards asked: <\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p>&#8220;It looks like I&#8217;m missing an X-Robots-Tag. How do I resolve this issue?&#8221;<\/p>\n<\/blockquote>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"502\" src=\"https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-07-16-1024x502.png\" alt=\"\" class=\"wp-image-23222\" title=\"\" srcset=\"https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-07-16-1024x502.png 1024w, https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-07-16-300x147.png 300w, https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-07-16-768x377.png 768w, https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-07-16-1536x753.png 1536w, https:\/\/kwebby.com\/blog\/wp-content\/uploads\/2024\/08\/2024-08-30_16-07-16-2048x1004.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Here\u2019s what John said:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Not an Issue<\/strong>: John said missing the X-Robots-Tag is not an issue. It\u2019s just a mechanism for specific directives.<\/li>\n\n\n\n<li><strong>Purpose of Tags<\/strong>: He explained the X-Robots HTTP header and robots meta tag are only relevant if you want search engines to treat a page differently. For example if you want a page to be no-indexed these tags can tell search engines to apply a \u201cno-index\u201d directive.<\/li>\n\n\n\n<li><strong>Default Treatment<\/strong>: If a page doesn\u2019t have an X-Robots-Tag or a Robots meta tag it will be treated like any other page. That means it will be indexed by search engines based on default behaviour.<\/li>\n\n\n\n<li><strong>Indexing is Possible<\/strong>: Most importantly John said without these tags the page can and will be indexed.<\/li>\n<\/ul>\n\n\n\n<p>This answers the flexibility of SEO and that missing X-Robots-Tag is not an issue unless you need to control indexing.<\/p>\n\n\n\n<p>In summary the X-Robots-Tag gives you options to control how search engines index your content but missing it isn\u2019t the end of the world \u2013 understanding what it does lets you make informed decisions about your website\u2019s visibility and ultimately your SEO.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In the digital marketing world, controlling your website\u2019s visibility to search engines is key. Enter the X-Robots-Tag, a powerful but often overlooked tool to fine-tune&hellip;<\/p>\n","protected":false},"author":1,"featured_media":23223,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[277,3],"tags":[],"class_list":["post-23220","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-advanced-seo-techniques","category-seo"],"_links":{"self":[{"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/posts\/23220","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/comments?post=23220"}],"version-history":[{"count":0,"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/posts\/23220\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/media\/23223"}],"wp:attachment":[{"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/media?parent=23220"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/categories?post=23220"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kwebby.com\/blog\/wp-json\/wp\/v2\/tags?post=23220"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}