Safety stock is the difference between stockouts that cost you customers and a buffer that keeps you selling. Here is the exact formula — and how to calculate it for your store in under 10 minutes.
You run out of your best-selling product on a Tuesday afternoon. By Wednesday morning, you have six customer emails asking where their order is, two chargebacks in progress, and a supplier who can't ship for another 12 days.
This is what happens without safety stock. And it is entirely preventable.
Safety stock is extra inventory you hold as a buffer against two things that are always outside your control:
Without safety stock, any deviation from your forecast leaves you exposed. With safety stock, you absorb the variation without your customers ever noticing.
Safety stock is not waste. It is insurance. The question is not whether to hold it — it is how much. Too little and you stockout. Too much and your cash is tied up in inventory sitting on a shelf.
The standard formula used by most inventory planners is:
Safety Stock = Z × σ_LT × D_avg
Where: - Z = service level factor (see table below) - σ_LT = standard deviation of lead time (in days) - D_avg = average daily demand (units/day)
| Service Level | Z Score |
|---|---|
| 90% | 1.28 |
| 95% | 1.65 |
| 98% | 2.05 |
| 99% | 2.33 |
A 95% service level means you want to avoid stockouts 95% of the time. For most Shopify stores, 95% is the right starting point.
Let's say you sell a skincare product with the following metrics:
Safety Stock = 1.65 × 3 × 15 = 74 units
That means you should always have at least 74 units on hand as a buffer, on top of your regular cycle stock.
If you don't have enough data to calculate standard deviation, use this simplified version:
Safety Stock = (Maximum Daily Sales × Maximum Lead Time) − (Average Daily Sales × Average Lead Time)
Using the same product: - Max daily sales: 25 units - Max lead time: 20 days - Average daily sales: 15 units - Average lead time: 14 days
Safety Stock = (25 × 20) − (15 × 14) = 500 − 210 = 290 units
This conservative formula is better for high-revenue SKUs where a stockout would be expensive. Use the statistical formula for everything else.
Safety stock tells you your buffer. Reorder point tells you when to order.
Reorder Point = (Average Daily Sales × Lead Time) + Safety Stock
Using our example: (15 × 14) + 74 = 284 units
When stock drops to 284 units, place your next purchase order. By the time stock arrives (14 days later), you will still have your 74-unit safety buffer remaining.
A fast-moving hero product with volatile demand needs a completely different safety stock calculation than a slow-moving accessory. Segment your SKUs by: - Velocity (fast / medium / slow / dead) - Lead time variability (reliable vs unpredictable suppliers) - Stockout impact (high margin vs low margin)
Demand patterns change every quarter. Your summer bestseller is not your winter bestseller. Seasonal shifts, new marketing campaigns, and changing customer behaviour all alter your actual daily demand. Recalculate safety stock at least every 90 days.
Shopify does not have a built-in safety stock field. Most merchants either track it in a spreadsheet (which gets out of date) or just keep a rough mental estimate (which is not an estimate at all — it is a guess). Neither is reliable at scale.
The more variable your demand, the more safety stock you need. Here is how the same product looks at different variability levels:
| Demand Variability | Safety Stock Needed (95% SL) |
|---|---|
| Low (σ = 2) | ~50 units |
| Medium (σ = 5) | ~124 units |
| High (σ = 10) | ~248 units |
This is why fashion and seasonal products require far more safety stock than commodity items — demand swings are much wider.
For stores with fewer than 50 SKUs, spreadsheets work. For anything above that, manual calculations become a full-time job.
CoreCaptain automatically calculates safety stock for every SKU in your catalogue based on your actual sales history and supplier lead times. When a product drops below its safety threshold, you get an alert before you are at risk — not after you have already stocked out.
The safety stock calculator in the Operations tab updates dynamically as your demand patterns change, so your buffers are always calibrated to current reality rather than last quarter's data.
| Store Type | Recommended Service Level | Why |
|---|---|---|
| Fashion / Seasonal | 90–95% | Demand is volatile; overstocking is expensive |
| Health & Beauty | 95–98% | Repeat customers; high churn on stockouts |
| Electronics | 95% | High unit value; moderate demand variability |
| Home & Garden | 90% | Lower repurchase frequency; more tolerance |
| Food & Perishables | 98–99% | Expiry adds complexity; stockouts are critical |
Safety stock is one of the highest-leverage calculations in inventory management. Get it right and you stop losing customers to stockouts. Get it wrong and you are either running out constantly or tying up cash in dead inventory.
The formula is straightforward. The hard part is keeping the inputs current — and that is exactly where automation pays for itself.
CoreCaptain detects phantom stock, sync errors, and inventory discrepancies automatically. 14-day free trial, no credit card required.
Start Free Trial