Articles on: Site editing
This article is also available in:

Creating a password-protected page

If you'd like to show the content of some pages to the specific visitors only, you can protect those pages with a password. Here are the possible cases when this will come in handy:

You can place educational materials on specific pages and show them to your students only.
You can sell some resources and give access to them only after the payment is made.
You can determine different levels of access to the content on your website. Place this content on different pages, set different passwords to them and share the passwords with the relevant people.

It's worth noting that whatever useful the restriction can be, it does not guarantee 100% security. This method relies entirely on the password you choose and also on the people you share it with. If someone gives the password to the third party, they will also be able to access the page. Currently it's not possible to create unique passwords for different people. Still, this method covers most basic scenarios and allows you to have a greater control of your website content.

Password-protection is accomplished with a pop-up that opens immediately after the page loads. The visitor will have to enter the correct password in the pop-up to display the page. The pop-up window is stretched to the full screen and cannot be closed.

Follow the instructions below to create a password-protected page.

Creating a password-protected page



To add a pop-up window on your site, open the Pop-ups tab on the toolbar:



Click on + Add Pop-up at the bottom of the menu:



In the pop-up gallery select the Custom block:



In the pop-up editing mode, customize the block design according to your needs — add text, background, change paddings, etc. For more information, check the Adding a custom block artcle:



Tip: The Adding and customizing a pop-up article will help you to set your pop-up.

After that, hover over the block, click on the "plus" and add a contact form:



Hover over the contact form and open its settings by clicking on the "gear":



Remove the current fields from the contact form and leave only the Short text :



Open the field settings by clicking on the "gear" next to it, change the field name, and enable the Make this field required option, so the users won't be able to submit a form until they enter a value in this field:



Scroll down and enter the password for the page in the Exact value field:



This is the password you will share to give access to a page.

Note: Remember that page security depends on the password you choose. We recommend using strong passwords with at least 8 characters, uppercase, and lowercase characters and numbers.
Tip: Since all requests from the form come to the CRM in your account, you can also collect additional information about your users, such as name or email address. The Customizing the layout of a contact form article will help you add other fields to your form.

If necessary, you can go to the Integrations tab and deactivate the Email switch so that when your site visitors submit a password, you will not receive notification emails:


After you've configured the fields, go to the Action tab and select the Close pop-up action:



This way, after entering the correct password in the pop-up, the user will be automatically redirected to the needed page.

Tip: Go ahead and adjust the style of the contact form according to the Customizing the style of a contact form article.

Now, you need to set the correct pop-up display parameters. For that, go to its settings and in the Triggers tab, enable the Show after page load option, and then set the delay to 0 seconds:



Enable the Show on pages option and select the needed page that you want to protect:



At the bottom of the Triggers tab, in the Frequency drop-down list, select Every time:


Go to the Behavior tab and turn off the Close on pressing Escape or clicking outside the pop-up option:



Access the Layout tab, turn on the Stretch to full screen option and toggle off the Show "X" icon to close the pop-up :



This way, you've disabled all possible ways to bypass the page protection. Now, the user will not be able to access it by simply closing the pop-up. The page will be displayed only after one correctly fills in the form.

Publish your site for the changes to appear live.

Updated on: 12/05/2023

Was this article helpful?

Share your feedback

Cancel

Thank you!