How to Password Protect a Page in WordPress and Divi

When building websites with WordPress and Divi, there might be times you want to Password Protect a Page in WordPress for various reasons. Luckily, WordPress has this ability built right into it, so we can Password Protect any Page in WordPress super easily without needing any additional tools or plugins!

In this post, we will take a look at why you might want to Password Protect a Page in WordPress, then show you exactly how to do just that!

You can watch the video, or follow along with the text, whatever works best for you 😎

Video Tutorial

Why Password Protect a Page in WordPress?

There could be a bunch of great reasons you may want to Password Protect a Page or Specific Content Block in WordPress to prevent the wrong people from seeing something.

A common use for this might be when you are working on a Landing Page redesign and you only want the client to be able to go in and view your work-in-progress because if this was a page that was indexed by accident, it could damage a brand and cause some serious client dissatisfaction.

Another common scenario is where you want information being communicated to specific group folks, like a price list of your products for wholesales, so it would be best to create a Password Protected Page which they can access.

You might be here for a different reason, but regardless of the why, this is a useful thing to know which is very easy to implement.

How to Password Protect a Page in WordPress

Now, I did not lie when I said this will be super easy, just follow along with the steps below to Password Protect your WordPress Page:

  1. Log into the backend of your WordPress Install.
  2. Head over to Pages > Edit the Page that you want to Password Protect.
  3. Under Publish on the right side column, click Edit next to Visibility.
  4. Now select “Password protected” from the options that appear and enter a password of your choosing…please don’t make this “password” 😉
  5. Hit that Publish or Update button, ALL DONE!

Now when you visit this page on the frontend you will be greeted with a password prompt before you can view the content.

NOTE: You can password protect Posts the same way, this is not limited to Pages.

Password Protect a WordPress Page or Post
A Password Protect a WordPress Page or Post

How to Password Protect your Entire WordPress Site

Password Protected By Ben Huson

Coming Soon Page, Maintenance Mode & Landing Pages by SeedProdFor those times when you might be working on the launch of a new site for a client, you’d definitely want the entire site locked down until you are ready to launch.

Two popular ways to do this depending on your skill level are either a plugin or using HTTP authentication. Since we want to keep things simple for this tutorial, we will look at a plugin. There are a few options like Coming Soon Page, Maintenance Mode & Landing Pages by SeedProd that offer a ton of features and a full-fledged maintenance mode.

This might be a bit overkill in many situations, so we will use a more lightweight solution called Password Protected by Ben Huson.

PRO TIP: If you need help generating a strong password, check out our FREE Password Generator.

Follow along with the steps below to Password Protected your entire WordPress site:

  1. Log into the backend of your WordPress Install.
  2. Head over to Plugins > Add New.
  3. Search for “Password Protected” by Ben Huson then install and activate the plugin.
  4. Now we’ll go to Settings > Password Protected.
  5. Check the “Enabled” box next to the “Password Protected Status” field then set your password below. The same rules apply, please don’t use “password”.

Now when you visit your WordPress site on the front end you will be greeted with a password prompt before you can view the site.

Password Protected By Ben Huson Settings

How to Password Protect Blocks of Content on a Divi Page

Ok, now on to the good stuff. As we’ve shown, WordPress allows you to Password Protect entire pages very easily using its built-in features, but what happens when you only want to restrict access to any section or element on your Page? Well, if you are using Divi, then you are in luck because this is exactly what Divi Protect does.

You can follow along below even if you don’t own Divi Protect (yes 😉 ) by visiting this link which will generate a temporary WordPress install with Divi Protect.

Follow along with the steps below to Password Protect any Section or Element on a Divi  WordPress site that has Divi Protect Installed:

  1. Log into the backend of your WordPress Install.
  2. Head over to Divi Engine > Protect Sections > Add New.
  3. Name the Divi Section that will be protected and activate the Divi Builder.
  4. You can build anything here, but let’s just add a Single Column Row here and place a Contact Form module inside the Column.
  5. With our Password Protected Section styled and ready, we can add our password in the column on the right.
  6. Copy the Unique Section Shortcode below the password and Publish/Update this Section.
  7. Head over to the page where you would like to add a Password Protected Section and edit it.
  8. Now all you need to do is add the Divi Protect module where you want to display your Password Protected Section and select the section we created on the Content Tab.
  9. Hit Publish and check out your page on the frontend of the site. ALL DONE!

Now when you visit your Divi page on the front end you will be greeted with the unprotected content, as well as a password prompt that will reveal the Password Protected Section.

Access Granted! You did it!!

WooCommerce Checkout with No Order Bump

Conclusion

Whatever your reason for needing to Password Protect your WordPress Websites, Pages, or Sections, we hope this tutorial was helpful in showing you some handy options for implementing it quickly and securely.

0 Comments

Submit a Comment

Explore more from Divi Engine