Create cookie cart before add to cart

Topic summary

A developer working with Shopify’s Dawn theme wants to modify the default cart cookie behavior. They’re seeking one of two solutions:

Primary Goal:

  • Create the cart cookie immediately when the page loads, before any “Add to Cart” interaction occurs

Alternative Approach:

  • If creating a custom cart cookie, find a way to overwrite or integrate it with the default cart when “Add to Cart” is clicked

Current Status:

  • The issue remains unresolved
  • Store URL and password have been shared for troubleshooting
  • Awaiting technical guidance on implementing either solution
Summarized with AI on November 2. AI used: claude-sonnet-4-5-20250929.

Hello everyone, I am currently using the Dawn Theme. When I click ‘Add to Cart,’ a new cart is created in the cookie. I would like to ask how to create that cookie cart even when the page is loaded for the first time and the ‘Add to Cart’ button hasn’t been clicked yet. Or, if I create a cart in the cookie, how can I overwrite the default ‘cart’ when clicking ‘Add to Cart’?

Please share store URL and passcode as well.

1 Like

this is my web: https://onmanedev.myshopify.com/ password 123456