> 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/content-to-lock/cart-page.md).

# Cart page

Lock the storefront cart page itself, separate from conditions about what's inside the cart.

The **Cart page** content type locks your storefront's cart page as a whole — for example, requiring a visitor to sign in or subscribe before they can view their cart and proceed toward checkout.

{% hint style="info" %}
Don't confuse this with [Cart conditions](/b2b-lock-password-protect/access-rules/cart-conditions.md). Cart page is *what you're locking* (the cart page itself, on any other lock). Cart conditions are an *access rule* you can add to a lock on other content (like a product) that checks whether specific items, or a quantity or subtotal, are already in the visitor's cart.
{% endhint %}

## Create the lock

1. Open **Locks** in the app's navigation and click **Create lock**.
2. Give the lock a descriptive name, for example "Cart — sign-in required."
3. On the **Lock setup** tab, open **Content to lock** and choose **Cart page**.

<figure><img src="https://27754559-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FF4qMYopXntYz9YgUqZSo%2Fuploads%2Fgit-blob-389b689d79f66582b813e33fd667942d01f947c2%2Fscreenshot-locks-content-picker-cart-page.png?alt=media" alt="The content picker with Cart page selected as the content type."><figcaption><p>Choose Cart page to lock the entire storefront cart page.</p></figcaption></figure>

{% hint style="warning" %}
Locking the cart page may require a paid plan depending on your current plan.
{% endhint %}

Cart page has no extra targeting options — selecting it locks the whole `/cart` page, so there's nothing else to configure on this tab besides the lock's name.

## Add an access rule

4. Switch to the **Unlock rules** tab and add at least one rule. See [Access rules overview](/b2b-lock-password-protect/access-rules/overview.md) for the full catalogue.
5. Add every required condition to the access key. All conditions must be satisfied. See [Combining rules](/b2b-lock-password-protect/access-rules/combining-rules.md).

{% hint style="info" %}
A Cart page lock doesn't have its own "Blocked visitor behavior" panel — there's no price or Add to cart to hide on the cart page itself. Use the rule's messages and, if needed, a redirect to control what a blocked visitor sees. See [Redirect after access](/b2b-lock-password-protect/lock-behavior/redirect-after-access.md).
{% endhint %}

## Save

6. Click **Save**. The lock takes effect on your storefront as soon as the app embed is enabled.

## Related docs

* [Locks overview](/b2b-lock-password-protect/locks/overview.md)
* [Cart conditions](/b2b-lock-password-protect/access-rules/cart-conditions.md)
* [Access rules overview](/b2b-lock-password-protect/access-rules/overview.md)
* [Manage locks](/b2b-lock-password-protect/locks/manage-locks.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/content-to-lock/cart-page.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.
