If you have a page or post on your WordPress site that you would like to keep private, there are a few different ways to do this. You can use the default WordPress privacy settings to hide the page/post from the public, or you can use a plugin. This article will teach you how to hide a page in WordPress using different methods.
If you have no time to mess up with the settings of your WordPress website, we at WebBusinessCreation can help you with it.
Why Is It Necessary to Hide a Web Page?
There can be several reasons why you might want to keep a web page private.
The Project is not ready for the public eye
When you create a new website, you might want to keep it hidden from the public until it’s ready for launch. In this case, you may have to hide all pages of your site from the visitors.
When you have a page with information that is no longer relevant to your site visitors, you may want to keep it hidden instead of deleting it. This way, the information will still be available to you, but it will be hidden from the public.
If you have a page with sensitive information, such as customer data, you may want to keep it hidden and password-protected. Only visitors who have the password will be able to view the page in this manner.
Not beneficial to the site SEO
Some pages are pointless and have no value to the website. If a page is not beneficial to your site’s SEO, you may want to keep it hidden, as according to SEMRUSH, low-quality content can hurt your site rankings.
How To Hide A Page In WordPress
Because your needs may differ, we’ve divided this guide into five sections. Some site owners want to hide only some pages, while others want to hide the whole website from the visitors. Some owners would only want to hide specific pages from search engines but not from visitors. Some other owners would only want to hide the title of the page. To cover all these cases, we have created the five sections below.
- How to Hide a WordPress Page From Search Engines
- How To Hide A WordPress Page From Visitors
- How To Hide All Pages Of A WordPress Website From Google
- How To Hide A WordPress Site From Visitors
- How To Hide The Title Of A Page In WordPress
How To Hide A WordPress Page From Search Engines
Important: Hiding pages from search engines involves using the NoIndex tag and editing the robots.txt file, which can harm your site’s ranking if incorrectly used. So, if you are not comfortable tweaking these files, it’s best to hire a WordPress developer to do it for you.
Using Rankmath Plugin
This is the easiest way to hide a WordPress page from Google and other search engines. You can use the free Rankmath SEO plugin to easily hide any WordPress page you want.
If you have another SEO plugin or prefer not to use Rankmath, many other SEO plugins also have this option. We prefer Rankmath because it is easier for beginners than other SEO plugins.
To get started with this method, first of all, you’ll have to install and activate the Rankmath plugin. You can install the RankMath plugin by navigating to Plugins -> Add New on your WordPress admin panel.
After you’ve installed and activated RankMath, go ahead and edit the post or page you want to hide from search engines. On the post-edit screen, you will see the Rankmath options in the top right corner of your screen.
Scroll down to the robots meta box after selecting the Advanced tab. In this box, you need to select the option that says “No Index.”
Don’t forget to click on the “Update” or “Publish” button to save your changes. That’s it! The post/page will now be hidden from Google and other search engines.
Using Robot.Txt File
If you need to hide more than one page at once and have some coding knowledge, this method will be easier. However, if you’re not comfortable with code, we recommend using the above method, as messing with code might break your site.
The easiest way to add the code is by using a WordPress plugin like Rankmath, Yoast SEO, or All in One SEO Pack. These plugins have an interface to edit the robots.txt file, and you can easily add the code without touching any files.
In Rankmath, you can access the robots.txt file through Rankmath -> General Settings -> Edit Robots.txt.
If you don’t want to use any WordPress plugin, you will need to connect to your site using an FTP client and edit the robots.txt file located in the root directory of your WordPress site.
Once you’re connected, open the robots.txt file and add the following code at the end of the file:
Disallow: /"The page you want to hide."
The code above will tell all search engine bots to stay away from your WordPress pages.
Remember to replace “The page you want to hide” with the actual URL of the WordPress page that you want to hide. For example, if you should hide a page with the URL “example.com/contact-us,” then you need to use the following code:
Once you’ve added the code, save your changes and upload the robots.txt file back to your server. That’s it! You have now successfully hidden the WordPress page from search engines.
Using this method has advantages as well as some disadvantages. The advantage is that you can hide multiple WordPress pages at once by adding the code for each page.
The disadvantage, however, is that anyone who knows about the robots.txt file can easily find all the pages that you’re hiding. If someone wants to find your hidden pages, all they have to do is visit your robots.txt file.
Further, while most search engines follow your instructions in the robots.txt file, some search engines might ignore your robots.txt file altogether. So, it’s not a foolproof method to hide your WordPress pages from search engines.
Therefore, we recommend using this method only if you’re comfortable with the code and know what you’re doing. If you’re not comfortable with code, then we recommend using the first method, as it is much easier.
How To Hide A WordPress Page From Visitors
You can hide pages from your visitors in two ways.
- Changing Visibility Options
- Switching It Into Draft
Changing Visibility Options
The easiest way to hide a WordPress page from your visitors is by changing the visibility options. This can be done while creating a new page or editing an existing page.
On the post-edit screen, you need to click the “Settings” button on the top right-hand corner. If you haven’t installed any SEO plugin, Post settings will appear automatically. If not, you have to access it by clicking this settings button.
Now select the Visibility options.
You will come across a popup like this.
Here, you can either make your post/page public, private or password-protected. If you want to hide your post from the public, you need to select “private” from the options.
This will change your post/page status from “publish” to “private.” Once you update your post, it will only be visible to logged-in users of your WordPress site.
Private posts/pages are not visible on your website, and they can’t be found by any search engine. Hence, this is the most effective way to hide a WordPress post or page from the public.
You can also “password protect” your WordPress posts and pages. Password-protected WordPress content is only visible to users who know the password. Password-protected posts and pages are also not visible on your website, and they can’t be found by any search engine.
Password protection is useful when you want to give access to your content to specific people only. For example, you might want to give access to a client or customer, but you don’t want the general public to see it.
Note: If you have published the same post as a public post before, Google may already have indexed it in its search results. In that case, even if you make the post private, it will still appear in Google search results until it gets de-indexed by Google.
Switching It Into Draft
Another way to hide your WordPress pages from the public is by changing their status from “publish” to “draft.” Doing this will take your page offline, and it won’t be visible on your website.
Only logged-in users with sufficient user privileges can view and edit draft posts in WordPress. As a result, this is an effective way to hide your WordPress pages from the public.
To change the status of a WordPress post or page from “publish” to “draft,” simply edit the post/page and change the status from “publish” to “draft” by clicking the “Switch to Draft” setting on the top of the page.
Once you update your post, it will be taken offline, and it won’t be visible on your website.
How To Hide All Pages Of WordPress Website From Google
If you want to hide the entire site from search results, you will have to “No Index” the entire site.
Using the settings in WordPress Dashboard
This is the easiest method if you don’t want your site to appear on search engine results pages (SERPs). This way, you don’t need any plugins, and you can do it from your WordPress dashboard.
First, you need to log in to your WordPress dashboard and go to Settings » Reading page.
On this page, you need to look for the ‘Search Engine Visibility option. By default, this option is turned off, which means that your WordPress site is visible to search engines.
You need to turn on this option by checking the box next to the Discourage search engines from indexing this site option.
Click on the “Save Changes” button to save your settings.
Now, when search engines try to index your site, they will see the following message in your robots.txt file:
This is a strong message telling all search engines not to index your site.
How To Hide A WordPress Site From Visitors
Adding a maintenance mode page is the simplest way to accomplish this.
There are many WordPress plugins available that you can use to add a maintenance mode page. For example, the “WP Maintenance Mode & Coming Soon” plugin. This plugin is simple to install and use. First, install and activate the plugin. Then click the “Activated” button on the Settings » WP Maintainance Mode, and you can easily add a nice maintenance mode page to your website.
You can also put the site in maintenance mode from your hosting control panel via WordPress Dashboard, adding a new maintenance mode page or editing the .htaccess file. However, we don’t recommend these methods as they are more complicated and can cause errors on your site if not done correctly.
How To Hide The Title Of A Page In WordPress
Manually hiding the title of a page is a bit hard if you are a beginner. But we have included the method as some site owners do not use Elementer or any other plugin.
First, you should find the Page id by going to WordPress Dashboard » Pages » All Pages.
Hover over “Edit” once you’ve hovered over the page of your choice. Don’t click it.
At the bottom of your browser, you’ll see a page ID in the URL. In the example above, the page ID is 580.
To hide the title of a specific WordPress page on your website, go to Appearance -> Customize. Then, click on Additional CSS and add the following code:
Remember to replace .page-id=580 with the ID number of the page whose title you want to hide. Now click the publish button to finish.
Hiding the Title of Every Page on Your WordPress Site
If you want to hide the title of every page on your WordPress site, then you will have to add the following CSS code in Appearance » Customize » Additional CSS from your WordPress dashboard.
This will hide the title of every page on your WordPress site. Note that this code will not work for posts.
If you have installed Elementor on your website, then you can easily hide the title of a page by following these steps:
1) Open the page in Elementor editor.
2) Click on the settings icon at the bottom left corner of the editor.
3) On the settings popup, click on the “Hide Title” option.
4) That’s it. Now you can click on the “Publish” button to save your changes.
If you do not want to add any code to your WordPress site, then you can use the “Hide Page and Post Title” plugin. After installing and activating the plugin, go to Pages » All Pages and Edit the Page you want to hide the title.
Under the Page Settings, you’ll see an option “Hide Page and Post Title” with a checkbox. To save your changes, check the box and click the “Update” button.
In this article, we have shown you how to easily hide a WordPress page or post from search engines and visitors. We also covered how to hide the page title in WordPress.
We hope this article has shown you how to hide a page in WordPress. You might also be interested in our comprehensive guide on How To Become a Web Designer Without a Degree.
How do I hide a page from the navigation menu in WordPress?
If you want to hide a page from the navigation menu in WordPress, then you will have to edit the menu and remove the page from it. To do this, go to the Appearance » Menus page and click on the “Edit” link next to the menu you want to edit.
On the right-hand side, you’ll see the list of pages. Simply remove the pages you want to hide from the navigation menu and click on the “Save Menu” button to save your changes.
Can you make pages private on WordPress?
Yes, you can make pages private on WordPress. To do this, go to the WordPress Dashboard » Pages » All Pages and click on the “Edit” link next to the page you want to make private.
On the right-hand side, you’ll see a “Visibility” option. By default, it is set to “Public.” You can change it to “Private” or “Password Protected.”
If you select the “Private” option, then only users with admin privileges will be able to view the page. If you select the “Password Protected” option, then a password will be required to view the page.