---
title: Cart
description: How shoppers add products, manage quantities and discounts, and continue to Shopify checkout.
url: "https://shop-docs.labs.vercel.dev/docs/anatomy/cart"
docs_index: /llms.txt
lastUpdated: 2026-10-13
type: guide
---

> For an index of all documentation, see [/llms.txt](/llms.txt).

Shoppers use one Shopify cart across product pages, the cart drawer, and the full cart page. [Shop Agent](/docs/anatomy/agent) uses that same cart when enabled.

The standard cart is ready to use without additional setup. The storefront remembers it in the same browser for up to 14 days.

## Shopper experience

Shoppers can add products, change quantities, remove items, apply discount codes, and proceed to checkout. The cart drawer is available throughout the storefront, and `/cart` provides a full-page view.

Quantity changes appear immediately while Shopify confirms them. If Shopify rejects a change, the cart returns to its confirmed state and shows the relevant error. Prices and totals indicate when they are still updating. Errors for a particular item appear alongside it.

Checkout stays unavailable until pending cart changes are confirmed. If checkout cannot start, an inline message lets the shopper try again without rebuilding the cart.

The cart displays discounts and sale pricing confirmed by Shopify. Bundles remain grouped so shoppers can understand which products belong together. Some bundle items cannot be edited individually.

When [customer authentication](/docs/anatomy/authentication) is enabled, signing in can attach the browser cart to the customer so checkout can use their saved details. Customer sign-in is optional and disabled by default.

## Important limits

- Cart recovery depends on the browser retaining its cookie and Shopify still returning the cart. Clearing browser data can start a new cart sooner than 14 days.
- Shopify determines inventory, prices, discounts, and which changes are allowed. An item being in the cart does not guarantee it will remain available at checkout.
- A cart change may finish after a chat response is interrupted. Check the cart before repeating the request.
- Preserve gift-card recipient details and bundle information when customizing the cart so that checkout receives everything needed to fulfill the order.

If you need to attribute cart activity to a particular Headless storefront, set `NEXT_PUBLIC_SHOPIFY_STOREFRONT_ID`. See [Environment Variables](/docs/reference/env-vars#optional).

## What’s next

Add gift messages, personalization, or other order details to suit your store. Make sure that information reaches checkout, and keep Shopify responsible for prices and availability. Custom bundle flows should make clear which items shoppers can change together or separately.

---

For a semantic overview of all documentation, see [/sitemap.md](/sitemap.md)

For an index of all available documentation, see [/llms.txt](/llms.txt)

For agent-facing discovery, including API and MCP surfaces, see [/agents.md](/agents.md)