How to Create Password Protected Posts in WordPress

Create Password Protected Posts in WordPress

Did you know that WordPress offer the ability to password-protect the posts that you write?

This feature doesn’t require a plugin and is a core feature of WordPress.

In this short, I’m going to show you how to create protected posts. Each WordPress post will need it’s own password, so this won’t work for protecting a whole site.

Step #1. Create a post

First, let’s create the post that we’re going to protect.

  • Go to Posts > Add new.
  • Add a title and some content.

If you’re going to write something that’s protected, make sure that the content is valuable. This guide shows how to set a minimum number of words for WordPress post.

How to password protected posts wordpress

Step #2. Set the Visibility for the post

  • In the “Publish” area click the “Edit” link next to Visibility.
password protected posts wordpress
  • Set the visibility to “Password protected”
  • Set a custom password. In the image below, I’m setting it to “something”.
  • Click the “Publish” button when you’re finished.
password protected posts wordpress

Step #3. Check the End Result

Now you can visit the front of your site to see if everything is working correctly.

  • Click the “Preview Changes” button to view your new post.
  • You will notice a password field. Here you need to type the password from Step #2.
  • Click “Submit”.
password protected posts wordpress

You will now see that your secret content is visible:

password protected posts wordpress

Summary

Hopefully this tutorial helps you. Adding a password to your posts really is quite a simple process.

If you need to control who can publish posts on your site, we highly recommmend the PublishPress plugin. Here’s a sample publishing workflow in WordPress.

If you need to protect your images (rather than just your posts) check out how to restrict Media Library access in WordPress and also how to protect image and file uploads in WordPress.

Have any questions about password-protecting your WordPress content? Leave us a question in the comments below …

Instructor

  • Valentin discovered Joomla in 2010, and since then he has considered it as the best CMS. Valentin has been coding extensions and templates for Joomla for many years and truly enjoys helping people build their own websites with Open Source tools. He lives in San Julián, Jalisco, México.

0 0 votes
Blog Rating
Subscribe
Notify of
1 Comment
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
katod

hi, i am trying to make a blog page with a password that only people with the password can see not only the post but the comments, too.  the comments seem to be open to the public, but why aren’t they protected with the password??  thank you, i am unbelievably frustrated trying to get this set up.  

1
0
Would love your thoughts, please comment.x
()
x