> For the complete documentation index, see [llms.txt](https://docs.samita.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.samita.io/b2b-lock-password-protect/locks/overview.md).

# Locks overview

What a lock is in Sami B2B Lock, Password Protect, and where to go next to build one.

A **lock** is the core building block of Sami B2B Lock, Password Protect. Every lock combines three things:

1. **Content to lock** — what part of your storefront the lock protects (the whole site, specific products, a collection, a page, blog content, a custom URL, the cart page, or checkout).
2. **Access rules** — the conditions a visitor must meet to get through (logged in, tagged, has a passcode, arrived via a secret link, and many more). When you add multiple conditions to an access key, the visitor must satisfy all of them.
3. **Lock behavior** — what happens to the protected content and to blocked visitors (hide price and Add to cart, hide from menus and search engines, redirect, tag the customer, or set how long access is remembered).

The lock editor is two tabs: **Lock setup**, where you name the lock and choose its content type, and **Unlock rules**, where you add access rules and — right alongside them, in the same tab — configure the lock's blocked-visitor behavior. Fill in both tabs, then save. All of your locks live on the [Manage locks](/b2b-lock-password-protect/locks/manage-locks.md) list, where you can enable, disable, duplicate, preview, or delete them.

{% hint style="info" %}
New to the app? [Create your first lock](/b2b-lock-password-protect/quick-start/quickstart.md) walks through building one from scratch, and [How locks work](/b2b-lock-password-protect/quick-start/how-locks-work.md) explains the underlying logic in more detail.
{% endhint %}

## Content types you can lock

Each content type has its own guide with the full setup, including the options specific to that type. Some content types may require a paid plan.

| Content type          | What it protects                                                                                                  | Guide                                                                              |
| --------------------- | ----------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- |
| Whole Website         | Your entire storefront, with an option to still allow the home page                                               | [Whole website](/b2b-lock-password-protect/content-to-lock/whole-website.md)       |
| Products and variants | All products, manually selected products, specific variants, or (from the create picker) by product tag or vendor | [Products and variants](/b2b-lock-password-protect/content-to-lock/overview.md)    |
| Collections           | One or more specific collections                                                                                  | [Collections](/b2b-lock-password-protect/content-to-lock/collections.md)           |
| Pages                 | Specific storefront pages                                                                                         | [Pages](/b2b-lock-password-protect/content-to-lock/pages.md)                       |
| Blogs and articles    | An entire blog or specific articles within it                                                                     | [Blogs and articles](/b2b-lock-password-protect/content-to-lock/blogs-articles.md) |
| Specific URL          | Any custom URL or path on your store                                                                              | [Specific URL](/b2b-lock-password-protect/content-to-lock/specific-url.md)         |
| Cart page             | The storefront cart page itself                                                                                   | [Cart page](/b2b-lock-password-protect/content-to-lock/cart-page.md)               |
| Checkout              | Checkout itself, using its own condition builder                                                                  | [Checkout](/b2b-lock-password-protect/content-to-lock/checkout.md)                 |

## The other two pieces of every lock

Once you've picked what to lock, every lock needs:

* **Access rules** — the conditions that decide who gets through. See [Access rules overview](/b2b-lock-password-protect/access-rules/overview.md) for the full catalogue and how multiple conditions are evaluated together.
* **Lock behavior** — what a blocked visitor sees and what happens after someone passes. See [Lock behavior overview](/b2b-lock-password-protect/lock-behavior/overview.md).

## Managing your locks

Once you have one or more locks, head to [Manage locks](/b2b-lock-password-protect/locks/manage-locks.md) to view, enable/disable, duplicate, preview, or delete them, and to use the Quick Setup templates if you're starting from scratch.

## Related docs

* [Manage locks](/b2b-lock-password-protect/locks/manage-locks.md)
* [Access rules overview](/b2b-lock-password-protect/access-rules/overview.md)
* [Lock behavior overview](/b2b-lock-password-protect/lock-behavior/overview.md)
* [Create your first lock](/b2b-lock-password-protect/quick-start/quickstart.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.samita.io/b2b-lock-password-protect/locks/overview.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
