Margin of Safety Calculator
Calculate the margin of safety between intrinsic value and market price, find your maximum buy price for a desired margin, or run bear/base/bull scenario analysis. Works with any currency.
Try another scenario
How to Use This Calculator
Tab "Margin of Safety"
Enter the intrinsic value per share (your estimate of what the stock is truly worth) and the current market price. The calculator shows the margin of safety as a percentage, along with a rating from "Thin margin" to "Deep value." A negative result means the stock appears overvalued.
Tab "Target Buy Price"
Enter your intrinsic value estimate and the desired margin of safety (e.g. 25%). The calculator shows the maximum price you should pay to achieve that margin. Buy at or below this price to maintain your desired safety cushion.
Tab "Scenario Analysis"
Enter three intrinsic value estimates — bear case (pessimistic), base case (most likely), and bull case (optimistic) — plus the current market price. The calculator shows the margin of safety under each scenario with a risk summary showing how many scenarios are favourable.
The Formulas
Margin of Safety = (Intrinsic Value − Market Price) / Intrinsic Value × 100%
Maximum buy price:
Max Buy Price = Intrinsic Value × (1 − Desired Margin%)
Rating scale:
< 0%: Overvalued (stock trades above intrinsic value)
0 – 15%: Thin margin (minimal buffer against errors)
15 – 25%: Moderate margin (reasonable for high-quality businesses)
25 – 50%: Strong margin (classic Graham territory)
> 50%: Deep value (large discount, but verify the estimate)
Intrinsic value is always an estimate. Use multiple valuation methods (DCF, earnings multiples, asset-based) and apply the margin of safety to account for uncertainty.
Worked Examples
Example 1 — Strong margin: intrinsic $80, market $55
An analyst estimates a stock's intrinsic value at $80 per share. The stock currently trades at $55.
At 31.3%, this exceeds Benjamin Graham's recommended 25% minimum. The $25 discount provides a meaningful buffer against estimation errors.
Example 2 — Target buy price: 25% margin on $120 stock
An investor estimates intrinsic value at $120 and wants at least a 25% margin of safety before buying.
The investor should buy at $90 or below. If the stock trades at $95, they should wait for a pullback or look elsewhere. Patience is a core value investing discipline.
Example 3 — Bear/base/bull scenarios at $55 market price
An analyst builds three valuation estimates for a stock currently trading at $55: bear case $60, base case $80, bull case $110.
All three scenarios show a positive margin of safety, which is encouraging. Even in the bear case the stock trades below intrinsic value, though the margin is thin. The base and bull cases show strong to deep value.
Understanding Margin of Safety
What Is Margin of Safety?
Margin of safety is the gap between what you believe a stock is worth (intrinsic value) and what the market is charging for it. The concept was introduced by Benjamin Graham in The Intelligent Investor and is the foundational principle of value investing. Warren Buffett has called it "the three most important words in investing."
Why Does It Matter?
Every intrinsic value estimate is inherently uncertain. You might overestimate future earnings, miss a competitive threat, or misjudge the discount rate. A margin of safety provides a buffer: if your estimate is off by 20% but you bought with a 30% margin, you still have a reasonable chance of making money.
How Much Margin Is Enough?
Graham recommended a minimum of 25-33% for individual stocks. The right margin depends on: the quality of the business (high-quality businesses warrant lower margins), the reliability of your estimate (DCF models need larger margins than asset-based valuations), and your risk tolerance (conservative investors demand more margin).
Intrinsic Value Estimation Methods
The margin of safety is only as good as the intrinsic value estimate behind it. Common methods include:
- Discounted Cash Flow (DCF): projects future free cash flows and discounts them back to present value
- Earnings multiples: compares P/E, EV/EBITDA, or P/B ratios to peers and historical averages
- Asset-based valuation: sums up the net value of tangible and intangible assets
- Dividend discount model: values stocks based on expected future dividends
Using multiple methods and comparing results gives a range of estimates, which is exactly what the Scenario Analysis tab is designed for.