# Use past stock-outs to decide what to restock

> Past stock-outs show which products shoppers will replace and which they won't. Connect Shopify to Claude and ask it to find every top-product stock-out of three days or more in the last year, measure how much demand moved to similar items, and rank products by sales lost per day. Restock first where sales vanished.

Type: Play (a chance to grow)
Run it: Before each stock order
Source: https://gooseworks.ai/playbooks/decide-what-to-restock-from-past-stockouts

## 1. Connect

Give your AI assistant read-only access to Shopify.

## 2. Ask

```text
Find every period in the last 12 months where a top product was sold out for 3 days or more. For each, how much of its usual sales moved to similar products, and how much simply disappeared? Rank products by sales lost per day out of stock.
```

## 3. Act

Restock first the products whose sales vanish when they're gone, not those whose buyers switch.

## Steps

1. Connect Shopify to Claude read-only, through a connector or MCP server if available, or upload 12 months of daily sales by product and inventory history.
2. Run the prompt so Claude finds each stock-out and measures how much demand moved to similar products.
3. Check that ad spend stayed steady during each stock-out, since a spend change would confuse the read.
4. Restock first the products whose sales vanish when they are gone.
5. Re-run before each stock order.

## What it tends to find

When one colour sold out, 70% of its sales moved to another. A different product's stock-outs lost almost everything. (Illustrative example, not a result from a named store.)

## Watch out

Make sure ad spend didn't change during the stock-out. That would confuse the read.

## FAQ

### How do I know if shoppers switched to another product?

Compare sales of similar products during the stock-out with their usual rate. If they rose by about what the missing product normally sold, buyers switched. If not, those sales were lost.

### Why does ad spend matter here?

If you cut or raised ads during a stock-out, sales of other products move for that reason too. Pick periods where spend stayed steady, or note the change so you can read around it.

### Can I do this with an assistant other than Claude?

Yes. Any assistant that can read your Shopify sales and inventory history, such as ChatGPT, Grok or Muse, can run the prompt on a live connection or an exported file.

### What if I don't have stock history?

Days with zero sales of a normally steady product are a rough stand-in for a stock-out. Shopify inventory reports can also show when stock hit zero for each item.
