How to Hide a WordPress Page from Google and Other Search Engines

If, for some reason, you want to hide a particular page on your website, it’s super easy to do if you’ve used WordPress to build your site.

There are many reasons why you’d want to hide a page – it could be for privacy or security, or maybe you just want some information concealed from the general public. In any case, you wouldn’t want your action to affect your site’s ranking. You see, SEO is very important, especially if you’re using your site for business.

Fortunately, Google (in particular) allows webmasters and website owners to hide their site’s pages (yes, as many as you wish). We will tackle three options on how to hide a WordPress page from Google and other search engines below.

Option 1: Use the Yoast SEO Plugin for WordPress

We recommend this option to experts and beginners alike. Aside from its simplicity, this method proves to be effective and safe as well. All you need to do is install the Yoast SEO plugin and activate it.

Here are the steps:

  1. In the Edit Post pane, you will find the Post Editor section. Go to the Yoast SEO box and click the Advanced Settings button.
  2. Find the Meta Robots Index section and click on the arrow pointing down. The dropdown menu will have “no index” as one of the options. Make sure that it’s set to “no index.”
  3. Just below the Meta Robots Index, you will find the Meta Robots Follow section. Click on the “no follow” option and make sure that it’s not set as “follow.”
  4. Click on save and publish the post (you can also choose to publish it at a later date).

That’s it. Remember, your goal here is to tell Google (and other search engines) that one or more pages in your website should not appear in their search results. That’s why you are asking them not to index or follow said pages.

Option 2: Use the Robots.txt File to Hide a WordPress Page

This option will require you to edit the robots.txt file so that you can save the changes on your site’s root directory. If it sounds complicated to you, it would be better to use option 1 instead. You see, there are risks involved when using this method – we’ll tell you about it in a little while.

Below are the steps to follow should you choose this option:

  1. Go to your website’s cPanel.
  2. In the robots.txt file, put an asterisk sign (*) in the User-agent line (e.g. User-agent: *)
  3. While still in the robots.txt file, put the URL of the page you want to hide (excluding your site’s domain name) on the Disallow line (e.g. Disallow: /your-post-or-page-url).
  4. Click Save.
  5. Upload the updated robot.txt file to your server.

As mentioned before, it’s quite risky to use Option 2 – so, proceed with caution. Keep in mind that robot.txt files are made accessible to the public. Therefore, techy people (including hackers) can find your hidden files even if they don’t appear in search engine results.

Note, too, that although Google and other reputable search engines obey the instructions on the robots.txt file, other search engines don’t. So basically, you are allowing other bots to access your hidden pages. These types of bots are usually the ones that spread malware and cause other serious problems on the internet (sensitive information from websites are especially targeted).[

Option 3: Use Password Protect in WordPress

Here’s another way to hide a WordPress post or page. With this method, you will allow Google and other search engines to index and follow your website. However, while that is the case, using the Password Protect option will make your post or page visible only to users who know the password.

Fortunately, the WordPress platform comes with a Password Protect feature. Therefore, you can use this option simply by logging into the backend of WordPress.

Here are the steps to follow:

  1. Click the Edit Post option in WordPress (choose a particular post).
  2. In the publish box, you have 3 options – Status, Visibility, and Publish Immediately. Click “Edit” in the Visibility option (it’s automatically set in Public). Choose Password Protected so that only those who know your password will be able to access your post/s or page/s.
  3. Create a strong password.
  4. Save your changes and publish the page.

Password Protect in WordPressWhich Option Should You Use for Your Wordpress?

We highly recommend option #1 for hiding a WordPress page from Google and other search engines. Aside from its simplicity, its effectiveness is also an added benefit.

Of course, you can also go for either option #2 or option #3. Just see which option suits your needs and intention to hide a WordPress page from Google and similar search engines – and go for it.