Safety Stock Calculator
- Daily demand averages 100 units but swings with a standard deviation of σd = 20 units, and the lead time is 7 days with its own standard deviation of σL = 0 days.
- Combine both sources of variability over the lead time: σLT = sqrt(7 × 20² + (100 × 0)²) = 52.92 units.
- A 95% cycle service level corresponds to z = 1.6449 standard deviations of cover.
- Safety stock = z × σLT = 1.6449 × 52.92 = 87.04 units, which rounds to 87 units held purely as a buffer against variability.
This safety stock calculator determines the buffer you should hold on top of average lead-time demand so that random variation in demand or supply does not cause a stockout during replenishment. Using the standard formula safety stock = z x sigmaLT, where sigmaLT is the standard deviation of demand over the lead time and z is the standard-normal value for your target cycle service level, the calculator returns a single safety stock figure in units. Standard z values used include 1.2816 for 90% service, 1.6449 for 95%, 1.9600 for 97.5%, 2.3263 for 99%, and 3.0902 for 99.9%. For instance, average daily demand of 100 units, sigma_d of 20 units, a constant 7-day lead time, and a 95% service level gives sigmaLT = 52.92 units and safety stock of 87 units.
The method is the accepted standard because it directly links your chosen cycle service level, the probability of no stockout in a replenishment cycle, to the measured variability of your demand and lead time. When lead time is constant, sigmaLT = sigma_d x sqrt(L), so variability grows with the square root of lead time rather than in direct proportion. When lead time also varies, sigmaLT = sqrt(L x sigma_d^2 + (d x sigma_L)^2), where d is average daily demand; the second term often dominates because it is multiplied by the full daily demand. The formula assumes demand is roughly normally distributed and daily demands are independent, and note that cycle service level is not the same as fill rate. This page shows the full formula, step-by-step workings, worked examples, and sources.
Worked examples
A steady seller at 95% service
Primary result: 87 units — demand variability over a 7-day lead time (σLT 52.92 units) times z = 1.6449 gives 87.04 units of buffer. (100 units/day · 20 units · 7 days · 0 days · 95% (z = 1.6449))
| Safety stock | 87 units |
| Demand variability over lead time (σLT) | 52.92 units |
| Safety stock before rounding | 87.04 units |
High volume at 99% service
Primary result: 208 units — pushing the service level from 95% to 99% roughly doubles the buffer for the same variability. (250 units/day · 40 units · 5 days · 0 days · 99% (z = 2.3263))
| Safety stock | 208 units |
| Demand variability over lead time (σLT) | 89.44 units |
| Safety stock before rounding | 208.07 units |
When the supplier is the problem
Primary result: 327 units — a lead-time standard deviation of just 2 days dominates the calculation, because it multiplies by all 80 units of daily demand. (80 units/day · 15 units · 10 days · 2 days · 97.5% (z = 1.9600))
| Safety stock | 327 units |
| Demand variability over lead time (σLT) | 166.88 units |
| Safety stock before rounding | 327.09 units |
The safety stock formula
Safety stock is the buffer held on top of average lead-time demand so that random variation in demand or supply does not cause a stockout during replenishment. The standard formula is safety stock = z x sigmaLT, where sigmaLT is the standard deviation of demand over the lead time and z is the standard-normal value for the target cycle service level. A safety stock calculator applies this formula directly, but the way sigmaLT is computed depends on whether lead time itself is stable or variable.
When lead time is constant, sigmaLT = sigma_d x sqrt(L). Here sigma_d is the standard deviation of daily demand and L is the lead time in days. Notice that variability grows with the square root of lead time, not in direct proportion: doubling the lead time increases sigmaLT by a factor of about 1.414, not by 2. When lead time also varies, sigmaLT = sqrt(L x sigma_d^2 + (d x sigma_L)^2), where d is average daily demand and sigma_L is the standard deviation of lead time. The second term often dominates because it is multiplied by the full daily demand, so even modest lead-time variation can drive a much larger safety-stock requirement than demand variation alone.
The z value sets the cycle service level, which is the probability of no stockout in a replenishment cycle; it is not the same as fill rate, the share of demand met from stock. Standard z values are: 90% service level = 1.2816, 95% = 1.6449, 97.5% = 1.9600, 99% = 2.3263, and 99.9% = 3.0902. Higher service levels require disproportionately more buffer stock because z rises faster at the upper end of the curve.
- Worked example: average daily demand 100 units, sigma_d 20 units, lead time 7 days, constant lead time, 95% service level gives sigmaLT = 52.92 units and safety stock = 1.6449 x 52.92 = 87.04 units, rounded to 87 units.
- Worked example: average daily demand 250 units, sigma_d 40, lead time 5 days, 99% service level gives sigmaLT = 89.44 units and safety stock = 208 units.
- Worked example: average daily demand 80 units, sigma_d 15, lead time 10 days with sigma_L of 2 days at 97.5% service gives sigmaLT = 166.88 units and safety stock = 327 units — most of it caused by lead-time variability, not demand variability.
Service levels and z values
A safety stock calculator relies on a key statistical input: the z value tied to your target service level. The standard formula is safety stock = z x sigmaLT, where sigmaLT is the standard deviation of demand over the lead time and z is the standard-normal value for the target cycle service level. Choosing a higher service level means accepting a larger z, which in turn increases the buffer you hold on top of average lead-time demand so that random variation in demand or supply does not cause a stockout during replenishment.
It is important to distinguish between two metrics that are often confused. Cycle service level is the probability of no stockout in a replenishment cycle; it is not the same as fill rate, the share of demand met from stock. A 95% cycle service level means you expect a stockout in roughly 5% of replenishment cycles, but the fill rate will usually be higher because most cycles still meet nearly all demand. The table below pairs common service levels with their z values and the implied stockout risk per cycle.
The formula assumes demand is roughly normally distributed and daily demands are independent; lumpy or seasonal demand needs different treatment. When lead time is constant, sigmaLT = sigma_d x sqrt(L), meaning variability grows with the square root of lead time, not in direct proportion. When lead time also varies, sigmaLT = sqrt(L x sigma_d^2 + (d x sigma_L)^2), where d is average daily demand; the second term often dominates because it is multiplied by the full daily demand. For example, average daily demand of 80 units, sigma_d of 15, lead time of 10 days with sigma_L of 2 days at 97.5% service gives sigmaLT = 166.88 units and safety stock = 327 units, most of it caused by lead-time variability, not demand variability.
| Cycle service level | z value | Implied stockout risk per cycle |
|---|---|---|
| 90% | 1.2816 | 10% |
| 95% | 1.6449 | 5% |
| 97.5% | 1.9600 | 2.5% |
| 99% | 2.3263 | 1% |
| 99.9% | 3.0902 | 0.1% |
The worked examples
To see how a safety stock calculator works in practice, consider three scenarios that surface the most common inputs. The first example uses average daily demand of 100 units, sigma_d of 20 units, a constant lead time of 7 days, and a 95% service level. Because lead time is constant, sigmaLT equals sigma_d multiplied by the square root of lead time: 20 x sqrt(7) = 52.92 units. The z value for a 95% cycle service level is 1.6449, so safety stock equals 1.6449 x 52.92 = 87.04 units, rounded to 87 units. Note that variability grows with the square root of lead time, not in direct proportion — doubling lead time does not double sigmaLT.
The second example raises the stakes. With average daily demand of 250 units, sigma_d of 40, lead time of 5 days, and a 99% service level, sigmaLT again uses the constant-lead-time formula: 40 x sqrt(5) = 89.44 units. The z value for 99% is 2.3263, so safety stock equals 2.3263 x 89.44 = 208 units. Even though lead time is shorter than in the first example, the higher service level and larger demand variability push the buffer well beyond 87 units.
The third example is the one that catches people off guard. Here average daily demand is 80 units, sigma_d is 15, lead time is 10 days, sigma_L is 2 days, and the target cycle service level is 97.5%. Because lead time itself varies, the calculator uses the expanded formula: sigmaLT = sqrt(L x sigma_d^2 + (d x sigma_L)^2). Plugging in the numbers gives sqrt(10 x 225 + (80 x 2)^2) = sqrt(2,250 + 25,600) = sqrt(27,850) = 166.88 units. The z value for 97.5% is 1.9600, so safety stock equals 1.9600 x 166.88 = 327 units.
What stands out in that third result is where the 327 units come from. The demand-variability term contributes 2,250 to the value under the square root, while the lead-time-variability term contributes 25,600 — more than ten times as much. The second term dominates because it is multiplied by the full daily demand of 80 units, so even a modest sigma_L of 2 days inflates the buffer dramatically. Most of this safety stock exists because of lead-time variability, not demand variability.
What the formula assumes — and how to need less stock
The standard safety stock formula — safety stock = z × sigmaLT — rests on two core assumptions: that demand is roughly normally distributed and that daily demands are independent of one another. When those conditions hold, the math is clean and a safety stock calculator can give you a defensible buffer. When they break down, the formula can mislead you. Lumpy or seasonal demand, where orders arrive in spikes rather than a steady stream, needs different treatment. The same is true when daily demands are correlated — for example, when a promotion drives several busy days in a row. In those cases, applying the standard formula without adjustment tends to underestimate what you need.
Cycle service level, the z value you feed into the formula, is the probability of avoiding a stockout during a single replenishment cycle. It is not the same as fill rate, which measures the share of total demand met from stock. That distinction matters because a 95% cycle service level can still leave you with a lower fill rate than you might expect, especially when order quantities are small. Standard z values for common targets are 90% = 1.2816, 95% = 1.6449, 97.5% = 1.9600, 99% = 2.3263, and 99.9% = 3.0902. Each step up the service ladder costs progressively more inventory, so the target you choose should reflect the item's importance, not a blanket policy.
The most powerful lever for reducing safety stock is shortening and stabilizing lead time. When lead time is constant, sigmaLT equals sigma_d × √L, so variability grows with the square root of lead time rather than in direct proportion. Cutting lead time from 10 days to 5 does not halve your safety stock, but it does reduce it meaningfully. When lead time itself varies, the formula becomes sigmaLT = √(L × sigma_d² + (d × sigma_L)²), where d is average daily demand. The second term often dominates because it is multiplied by the full daily demand, which is why a safety stock calculator will frequently show that lead-time variability drives more buffer than demand variability. In one worked example — average daily demand 80 units, sigma_d 15, lead time 10 days with sigma_L of 2 days at 97.5% service — sigmaLT reaches 166.88 units and safety stock totals 327 units, most of it caused by lead-time swings, not demand swings.
Beyond lead time, two other levers matter. Better forecasts shrink sigma_d, which flows directly through the formula and lowers the buffer for every service level. And not every item warrants the same target. C-items — low-value, low-criticality products — can often sit at a 90% cycle service level instead of 99%, which drops the z value from 2.3263 to 1.2816 and cuts safety stock by nearly half. Reserve the higher service targets for A-items where a stockout carries real cost.
FAQs
What is safety stock?
Safety stock is extra inventory held beyond expected lead-time demand to absorb variability in demand and supply. It acts as a buffer so you can keep fulfilling orders even when customers buy more than expected or your supplier delivers later than usual. Without it, any spike in demand or delay in supply would cause a stockout.
How is safety stock calculated?
Safety stock = z x sigmaLT. That is the service-level z value times the standard deviation of demand over lead time. The z value reflects how often you want to avoid a stockout, and sigmaLT captures how much your demand fluctuates during the replenishment window. Multiply them together and you get the buffer quantity.
What z value should I use for a 95% service level?
For a 95% service level use 1.6449. For 99% use 2.3263; for 90% use 1.2816. The z value grows as the target service level rises because you need a bigger buffer to cover less-likely but still possible demand spikes. Pick the z that matches the service level your business requires.
Is safety stock the same as the reorder point?
No — the reorder point is lead-time demand plus safety stock; safety stock is only the buffer part. The reorder point tells you when to place a new order, while safety stock tells you how much extra to keep on hand. You need both numbers, but they answer different inventory questions.
Why does lead-time variability matter so much?
It enters the formula multiplied by average daily demand, so a small sigma_L can outweigh all demand variability. When your supplier's delivery times are inconsistent, the effect on required safety stock grows quickly because every extra day of delay means more units of daily demand left uncovered during the wait.
How can I reduce safety stock?
Shorten or stabilise lead times, improve forecast accuracy, or accept a lower service level — the formula prices each lever. Faster and more reliable suppliers reduce the variability you must cover. Better forecasts shrink the standard deviation of demand. Accepting a lower service level lowers the z value. Each change lowers the buffer you need.