Newsvendor Model Calculator

Optimal order quantity565 units
Critical fractile (in-stock probability)70.6 %
Safety stock above mean demand65 units
Expected profit at the optimum$5,297.10
How this was calculated
  1. The newsvendor model balances two regrets: each unit short costs the underage cost Cu = price - cost = 20 - 8 = $12.00, and each unit left over costs the overage cost Co = cost - salvage = 8 - 3 = $5.00.
  2. The critical fractile is Cu / (Cu + Co) = 70.6% - the probability of meeting demand that the optimal stock should give. For normally distributed demand that fractile is z = 0.54 standard deviations above the mean.
  3. Optimal order quantity Q* = mean + z x sd = 500 + 0.54 x 120 = 565 units, of which 65 units are safety stock held purely against demand variability.
  4. At Q* the expected sales are 477.8 units and the expected leftover is 87.2 units, giving an expected profit of $5,297.10. Ordering the mean demand instead would satisfy only 50% of scenarios - the newsvendor model deliberately stocks past the mean whenever shortages cost more than leftovers.

This newsvendor model calculator finds the order quantity that maximizes expected profit for a single selling season with uncertain demand. Enter your price, cost, salvage value, and the mean and standard deviation of demand, and it returns the optimal order along with the critical fractile, safety stock, and expected profit. With a $20 price, $8 cost, $3 salvage, mean demand of 500 and standard deviation of 120, the calculator gives an optimal order of 565 units. The critical fractile for those economics is 70.6 %, the in-stock probability the order should target. That optimum holds 65 units of safety stock above mean demand, and the expected profit there is $5,297.10.

The method behind the answer is the standard newsvendor solution. Underage cost Cu is the margin lost per unit stocked out (price minus cost), and overage cost Co is the loss per unit left over (cost minus salvage). The optimal quantity is the critical-fractile quantile of the demand distribution: Q* = mu + z x sigma for normal demand. Ordering the mean, a fractile of 50 %, is only optimal when underage and overage costs happen to be equal, which is rarely the case in practice. This page shows the formula, step-by-step workings, worked examples and sources so you can check every number yourself.

Worked examples

Fashion buy

(8 $ · 20 $ · 3 $ · 500 units · 120 units)

Optimal order quantity565 units
Critical fractile (in-stock probability)70.6 %
Safety stock above mean demand65 units
Expected profit at the optimum$5,297.10

Perishables

(50 $ · 80 $ · 45 $ · 200 units · 40 units)

Optimal order quantity243 units
Critical fractile (in-stock probability)85.7 %
Safety stock above mean demand43 units
Expected profit at the optimum$5,684.10

Event merch

(15 $ · 22 $ · 14 $ · 1000 units · 300 units)

Optimal order quantity1,345 units
Critical fractile (in-stock probability)87.5 %
Safety stock above mean demand345 units
Expected profit at the optimum$6,505.95

Underage, overage and the critical fractile

Every newsvendor decision comes down to two costs that pull in opposite directions. The underage cost, Cu, is the margin you lose on each unit of demand you cannot fill: price minus cost. The overage cost, Co, is the loss on each unit you order but cannot sell: cost minus salvage. In a newsvendor model calculator, these two numbers are the inputs that turn a demand forecast into an order quantity. They matter because they set the balance point between stocking too little and stocking too much.

The balance point is the critical fractile, written Cu / (Cu + Co). It is the in-stock probability the order should target — the fraction of demand scenarios you want to be able to cover. When Cu is large relative to Co, the fractile is high and you should stock generously; when Co dominates, the fractile is low and you should stock lean. Ordering the mean, which corresponds to a 50 % fractile, is only optimal when underage and overage costs happen to be equal. That is a special case, not a default.

Work through the standard example. With a $20 price, $8 cost and $3 salvage, Cu = $20 - $8 = $12 per unit, and Co = $8 - $3 = $5 per unit. The critical fractile is 12 / (12 + 5) = 12 / 17, which is 70.6 %. That is the in-stock probability the order should target. With mean demand 500 and standard deviation 120, the optimal quantity is the critical-fractile quantile of the normal demand distribution: Q* = mu + z x sigma. The 70.6 % fractile sits about 0.54 standard deviations above the mean, giving an optimal order of 565 units — 65 units of safety stock above mean demand. The expected profit at that quantity is $5,297.10.

Notice what the fractile does not depend on. Cu and Co set the target probability entirely from the economics; the demand distribution only translates that probability into a unit count. Change the forecast and the order moves, but the 70.6 % target stays fixed as long as price, cost and salvage stay fixed. That separation is why the newsvendor model calculator is useful: it lets you test how sensitive the order is to the forecast without losing sight of the economics driving it.

A quick sanity check helps before trusting any output. Confirm that Cu uses price minus cost, not price alone, and that Co uses cost minus salvage, not cost alone. A salvage value close to cost shrinks Co and pushes the fractile up; a thin margin shrinks Cu and pulls it down. Get those two definitions right and the fractile, the safety stock and the expected profit all follow.

Critical fractile = Cu / (Cu + Co). With a $20 price, $8 cost and $3 salvage: 12 / 17 = 70.6 % — the in-stock probability to target, which yields an optimal order of 565 units.

From fractile to order quantity

Once you have the critical fractile, the newsvendor model calculator turns it into an actual order quantity in two short steps. First, convert the fractile to a z-score: the number of standard deviations above or below mean demand that corresponds to your target in-stock probability. Second, apply the formula Q* = mu + z × sigma, where mu is mean demand and sigma is the standard deviation. With normal demand, that z-score is all you need to place the order at the exact quantile the economics call for.

For the running example — a $20 price, $8 cost, $3 salvage, mean demand of 500 units and a standard deviation of 120 — the critical fractile works out to 70.6%. That is the in-stock probability the order should target. The z-score matching a 70.6% fractile is about 0.54, so the calculation reads Q* = 500 + 0.54 × 120, which gives an optimal order of 565 units. The gap between that order and mean demand is the safety stock: 565 − 500 = 65 units held above the average to cover demand uncertainty.

Those 65 units are worth seeing explicitly, because they are the whole point of the exercise. They are not a cushion added by habit or a round-number guess; they are the exact amount the critical fractile places above the mean. The expected profit at 565 units is $5,297.10. That figure is the benchmark for any alternative quantity — order more and leftover units start to bite, order less and you give up sales you could have served.

The direction of the adjustment follows directly from the two costs. Underage cost Cu is the margin lost per unit stocked out (price minus cost); overage cost Co is the loss per unit left over (cost minus salvage). When Cu is larger than Co, the fractile sits above 50% and the optimal order rises above the mean, as it does here. Ordering the mean — a fractile of 50% — is only optimal when underage and overage costs happen to be equal. Any imbalance between the two pushes the optimum away from average demand, and the z-score step is how far it pushes.

Run the same two steps on your own numbers and the newsvendor model calculator reproduces this path every time: fractile, then z-score, then Q* = mu + z × sigma, with the difference from the mean reported as safety stock. Check the output against the 565-unit example to confirm you have entered price, cost, salvage, mean and standard deviation in the right places before you commit an order.

Worked example: mean 500, standard deviation 120, critical fractile 70.6% → z ≈ 0.54 → Q* = 500 + 0.54 × 120 = 565 units, which is 65 units of safety stock above the mean. Expected profit at that order: $5,297.10.

Expected profit at the optimum

The $5,297.10 expected profit at the optimum is not a guess or a rule of thumb — it comes from a closed-form calculation based on the normal distribution. Once the newsvendor model calculator has the critical fractile and the optimal order quantity, it evaluates expected profit by combining the margin earned on units that sell with the salvage recovered on units that do not, weighted by the probability of each outcome. For normal demand, that weighting is done with the normal loss function, which captures the expected shortfall of demand above or below the order quantity in standardized units.

Here is how the pieces fit together for the example economics: a $20 price, $8 cost, and $3 salvage give an underage cost Cu of $12 (price minus cost) and an overage cost Co of $5 (cost minus salvage). Those costs produce a critical fractile of 70.6%, the in-stock probability the order should target. With mean demand of 500 and a standard deviation of 120, the optimal order is 565 units — 65 units of safety stock above the mean. That order sits at the 70.6th percentile of the demand distribution, exactly where the marginal cost of ordering one more unit equals the marginal benefit.

At that quantity, expected leftover and expected shortage balance in dollar terms rather than in units. The normal loss function supplies the expected number of units short and the expected number of units left over at 565 units, and each is multiplied by its respective cost: shortages by Cu = $12, leftovers by Co = $5. Because 565 is the critical-fractile quantile, the expected marginal loss from stocking one more unit (Co times the probability it is left over) equals the expected marginal gain (Cu times the probability it sells). Push the order above 565 and leftover costs dominate; drop it below and shortage costs dominate. The expected profit peaks precisely at that balance point, and for this example it is $5,297.10.

This is also why ordering the mean is not a safe default. Ordering 500 units targets only a 50% in-stock probability, which is optimal only when underage and overage costs happen to be equal. Here Cu is $12 and Co is $5, so the costs are far from equal and the optimum shifts upward to 565 units. Running the same numbers through a newsvendor model calculator lets you see the expected profit at the optimum alongside nearby order quantities, so you can confirm that the $5,297.10 figure is the peak rather than an arbitrary point on the curve.

The critical fractile sets the target in-stock probability (70.6% here); the normal loss function turns that target into expected leftover and shortage units, and those costs balance at the 565-unit optimum worth $5,297.10 in expected profit.

When the newsvendor model applies

The newsvendor model fits a specific kind of inventory decision: one order, placed before demand is known, for goods that will not carry over to a next selling season. Think of a retailer committing to a holiday assortment, a boutique buying a single run of a fashion line, a vendor stocking programs for one game, or a grocer ordering a perishable item that must be sold or salvaged by the end of the day. In each case the item is ordered once, demand is uncertain, and whatever is left has little or no value beyond a salvage recovery. If those conditions describe your situation, a newsvendor model calculator is the right tool, because it sizes the order around the trade-off between running short and having leftovers.

That trade-off is captured by two per-unit costs. The underage cost Cu is the margin lost on each unit you stock out of (price minus cost). The overage cost Co is the loss on each unit left over (cost minus salvage). When the margin is larger than the leftover loss, the model pushes the order above the average demand, because a shortage hurts more than a surplus. When the leftover loss is larger, it pulls the order below the average.

The optimal quantity is the critical-fractile quantile of the demand distribution, written Q* = mu + z x sigma for normal demand. The critical fractile is the in-stock probability the order should target. Take a $20 price, $8 cost, $3 salvage, mean demand of 500 units and a standard deviation of 120. The critical fractile for those economics is 70.6%, so the optimal order is 565 units. That optimum holds 65 units of safety stock above mean demand, and the expected profit there is $5,297.10.

Note what this example shows: ordering the mean, a fractile of 50%, is only optimal when underage and overage costs happen to be equal. Here they are not, so the mean order would leave money on the table. The same logic explains when the model does not apply. EOQ assumes repeating orders of a durable item with steady demand, and safety-stock models size buffers for ongoing items that are replenished continuously. Neither handles a single buying decision for a perishable or seasonal good. If you can reorder next week and carry the stock forward, use a replenishment model instead.

Quick test: one order, uncertain demand, and leftovers worth only salvage? Use the newsvendor model. Repeat orders of an ongoing item? Use EOQ or a safety-stock model.

FAQs

What is the critical fractile?

The critical fractile is Cu / (Cu + Co), the target in-stock probability for your order. With an underage cost of 12 and an overage cost of 5, it comes to 70.6%. That means the optimal order should cover demand in about 70.6% of scenarios, balancing the risk of running short against the cost of leftovers.

How many units should the example order?

The example should order 565 units. That is the mean demand of 500 plus 65 units of safety stock, sized to reach the 70.6% fractile. Ordering more than the mean protects against stockouts, which cost more than leftovers in this example, while still leaving room to avoid excessive overstock.

What are underage and overage costs?

The underage cost is the lost margin per stockout, calculated as price minus cost, which is 12 here. The overage cost is the loss per leftover unit, calculated as cost minus salvage, which is 5 here. These two costs set the critical fractile and therefore drive how much safety stock the calculator recommends.

What profit does the optimal order expect?

For the worked example with mean demand 500 and standard deviation 120, the optimal order expects a profit of $5,297.10. This figure reflects ordering at the 70.6% fractile, where the balance between underage and overage costs is optimized. Enter your own demand and cost figures to see your expected profit.

Why not just order the mean demand?

Ordering the mean targets a 50% fractile, which is only optimal when underage and overage costs are equal. Here stocking out costs more than twice overstocking, so the fractile rises above 50%. That is why the example orders 565 units, above the mean of 500, to guard against costly stockouts.

Does the model need normal demand?

No. The fractile logic works for any demand distribution, so the critical fractile Cu / (Cu + Co) applies regardless of the shape of demand. This calculator uses the normal form Q* = mu + z sigma to turn the fractile into a specific order quantity, so normal demand is assumed only for that conversion.

Sources

Related calculators

Economic Order Quantity (EOQ) Calculator
The order size that minimises total inventory cost: the classic square-root formula balancing ordering costs against holding costs.
Safety Stock Calculator
The buffer stock that keeps you selling through demand spikes and late deliveries: z times the standard deviation of demand over lead time, with lead-time variability included.
Bertrand Competition Calculator
Bertrand-Nash equilibrium prices, outputs and profits for two firms with differentiated products, from linear demand curves and marginal costs.