Magic Formula Investing: Joel Greenblatt's Strategy Explained
Magic formula investing explained: how Joel Greenblatt ranks stocks by earnings yield and return on capital, what the backtests show, and its limits.
Magic formula investing explained: how Joel Greenblatt ranks stocks by earnings yield and return on capital, what the backtests show, and its limits.
Disclosure: book titles on this page are affiliate links. As an Amazon Associate, Gingernomics earns from qualifying purchases.
Magic formula investing is Joel Greenblatt's rules-based method for buying good companies at bargain prices: rank every stock by earnings yield (EBIT divided by enterprise value) and by return on capital (EBIT divided by net working capital plus net fixed assets), add the two ranks, and buy the 20 to 30 best-scoring stocks, holding each for about a year. Greenblatt set it out in The Little Book That Beats the Market (2005). The formula is simple, but using it well requires understanding what it measures and where it can mislead you.
Where this fits: this is a Learning from the Masters article. The magic formula combines Criterion 1, great business, and Criterion 5, reasonable price, from the Five Criteria. It sits alongside the other lessons in our guide to the greatest investors of all time.
Who is Joel Greenblatt?
Joel Greenblatt was born in 1957. He earned a BS and an MBA from the Wharton School in 1979 and 1980. In 1985 he founded his fund, a hedge fund focused on special situations such as spin-offs, restructurings and mergers. Robert Goldstein joined him in 1989.
The fund’s early returns were exceptional. His Wikipedia biography cites figures from about 30% to 50% a year for 1985 to 1994, depending on the source and whether fees are included. In 1995 the fund returned outside investors' capital. Greenblatt also taught value investing at Columbia Business School for more than 20 years and co-founded the Value Investors Club website.
His books are You Can Be a Stock Market Genius (1997), The Little Book That Beats the Market (2005), The Little Book That Still Beats the Market (2010), The Big Secret for the Small Investor (2011) and Common Sense (2020).
What is magic formula investing?
The magic formula tries to automate one idea: buy good businesses at cheap prices. It uses one number for "good" and one for "cheap", then ranks companies on both.
Measure 1: return on capital (the "good" test)
Return on capital = EBIT divided by (net working capital + net fixed assets).
EBIT is earnings before interest and taxes, sometimes called operating profit. Net working capital plus net fixed assets is the tangible capital a business needs to operate: inventory, receivables and equipment, minus what suppliers fund.
Greenblatt uses EBIT so that companies with different debt levels and tax rates can be compared fairly. He uses tangible capital, excluding goodwill, because he wants to know how much the business itself earns on the capital it actually needs. A high figure suggests a business that generates a lot of profit without needing much money to grow.
Measure 2: earnings yield (the "cheap" test)
Earnings yield = EBIT divided by enterprise value.
Enterprise value is market capitalisation plus net debt. It is roughly what it would cost to buy the whole business, including its debts. Using enterprise value instead of market cap means a company cannot look cheap just because it carries a lot of debt.
A higher earnings yield means you are paying less for each dollar of operating profit.
How the ranking works
Greenblatt's steps, as summarised on the magic formula Wikipedia page, are:
- Set a minimum company size, usually a market cap above $50 million.
- Exclude utilities, financial companies and foreign companies listed through ADRs.
- Rank all remaining companies by earnings yield, highest first.
- Rank them again by return on capital, highest first.
- Add the two ranks together. The lowest combined score is best.
- Buy the 20 to 30 best-ranked companies, adding two or three positions a month over a year.
- Sell each holding after about a year, then replace it with a current top-ranked stock.
- Repeat for many years. Greenblatt stresses a horizon of at least five to ten years.
Utilities and financials are excluded because their capital structures make EBIT, working capital and enterprise value hard to compare with other companies.
What returns did the magic formula produce?
In The Little Book That Beats the Market, Greenblatt reported a backtest from 1988 to 2004. The formula returned about 30.8% a year against roughly 12% for the S&P 500, according to these notes on the updated edition.
Treat that figure with care. It is a backtest, not an audited track record. Independent studies since then have found smaller, though often still positive, excess returns. One 2020 study cited on the Wikipedia page found about 11.4% a year from 2003 to 2015, versus 8.7% for the S&P 500, with more volatility.
Greenblatt himself is candid that the formula often lags. In the updated edition he notes that it underperformed the market in roughly five of every twelve months and in about one year in four. He argues the hard part is sticking with it through those periods.
Worked example: ranking four companies
Here is a hypothetical example with round numbers. All figures are in millions.
| Company | EBIT | Enterprise value | Operating capital | Earnings yield / ROC |
|---|---|---|---|---|
| Company A | $100 | $800 | $400 | 12.5% / 25% |
| Company B | $50 | $1,000 | $100 | 5% / 50% |
| Company C | $80 | $500 | $800 | 16% / 10% |
| Company D | $70 | $500 | $200 | 14% / 35% |
Now rank each measure from best (1) to worst (4):
- Earnings yield ranks: C is 1st, D is 2nd, A is 3rd, B is 4th.
- Return on capital ranks: B is 1st, D is 2nd, A is 3rd, C is 4th.
- Combined scores: A is 6, B is 5, C is 5, D is 4.
Company D wins. It is neither the cheapest nor the highest-return business, but it is the best combination of both.
Notice what the formula avoids. Company B is a superb business but expensive, with a 5% earnings yield. Company C is cheap but earns only 10% on capital. The formula steers you toward the middle ground Buffett described: good businesses at fair or better prices.
What the magic formula does not tell you
The formula is a good screen, but a poor substitute for judgement. Its practical caveats matter.
- It uses one year of numbers. A cyclical company at peak earnings will show a high earnings yield and high return on capital, just before profits fall.
- It ignores the moat. High returns this year say nothing about whether competitors will erode them.
- It ignores management and share count. A company can rank well while diluting shareholders or making poor acquisitions.
- It does not check the balance sheet directly. Enterprise value captures net debt, but not debt maturities, interest coverage or pension deficits.
- Accounting quirks can fool it. One-off gains, capitalised costs and unusual working capital can distort both measures.
- It needs discipline most people lack. Greenblatt himself warns that most people abandon the strategy after a losing stretch.
- Taxes and costs reduce returns. Annual turnover of 20 to 30 positions creates trading costs and, outside tax-sheltered accounts, capital gains taxes.
- Backtests flatter. Real returns can be lower once you account for trading in smaller companies, data errors and changing markets.
Having worked in investor relations, I know how much a single year's reported EBIT can be shaped by timing, restructuring charges and one-off items. A screen that reads one year of numbers will sometimes read the wrong story. That is why the list is a starting point for research, not the end of it.
Where Greenblatt's approach struggles
The magic formula's biggest strength, its simplicity, is also its main weakness. It treats every company as a set of numbers, which means it cannot tell the difference between a temporarily cheap great business and a permanently declining one.
It is also a diversified, high-turnover strategy. That suits investors who want a mechanical process. It suits less well investors who want to own a small number of carefully researched businesses for many years, which is the approach we teach.
How we use this in the Five Criteria
We do not run the magic formula as a portfolio strategy. We use its logic as a first-pass screen, then test the best-ranked names against all five criteria.
| Magic formula idea | Five Criteria link | How we apply it |
|---|---|---|
| High return on capital | Criterion 1: Great business | ROIC of 15%+ for 5+ years, not just one year |
| No moat test | Criterion 2: Durable moat | Name the moat source; check ROIC held through a downturn |
| No management test | Criterion 3: Aligned management | Owner-oriented: meaningful insider ownership, disciplined use of cash, candour about mistakes |
| Enterprise value includes debt | Criterion 4: Sound balance sheet | Near-zero long-term debt; cash and total assets growing; share count flat or falling |
| High earnings yield | Criterion 5: Reasonable price | Price at or below about 70% of conservative intrinsic value |
The key upgrade is time. We require high returns on capital for at least five years, not one. That single change removes many of the cyclical traps the formula falls into. Our ROIC guide explains how to calculate it.
We also prefer free cash flow to EBIT at the price stage, because cash is harder to flatter than operating profit. Our guide to price to free cash flow shows how.
Common mistakes with magic formula investing
- Buying the list without looking. The formula cannot spot a fraud, a failing product or a one-off gain. Read the annual report of anything you buy.
- Using it on banks and insurers. The measures do not work for financial companies. Greenblatt excludes them for good reason.
- Quitting after a bad year. If you use it mechanically, a losing year is expected. Abandoning it then locks in the worst part of the strategy.
- Confusing earnings yield with dividend yield. Earnings yield measures operating profit relative to the whole business value, not cash paid to you.
- Ignoring cycles. A top-ranked steel or shipping company may be at peak profits. Check a full cycle, as our guide to red flags in a business explains.
Your Next Step
- Read our overview of lessons from the greatest investors of all time to see how Greenblatt fits alongside Buffett, Graham and others.
- Learn how to screen stocks quickly using the Five Criteria.
- Use our investment calculators to test returns and valuations yourself.
About the author: Cameron Hayes is a senior investor relations and finance professional who has worked in IR at Nasdaq Copenhagen-listed companies including Nilfisk and Maersk Drilling. He holds an MSc from Copenhagen Business School and a BCom from the University of Ottawa, and founded Gingernomics to teach individual investors the Five Criteria framework. Former employers do not endorse Gingernomics. More about Gingernomics.
The content on Gingernomics is for educational and informational purposes only and does not constitute financial advice. Always do your own research and consult a licensed financial advisor before making any investment decisions. Past performance is not indicative of future results.
Frequently asked questions
What is the magic formula in simple terms?
It ranks companies on how cheap they are (earnings yield) and how good they are (return on capital), then buys those with the best combined rank. Greenblatt described it in The Little Book That Beats the Market (2005).
Does magic formula investing still work?
Independent studies since the book have found positive but smaller excess returns than the original backtest, with long stretches of underperformance. It is a useful screen, not a guarantee.
How is the magic formula calculated?
Earnings yield is EBIT divided by enterprise value. Return on capital is EBIT divided by net working capital plus net fixed assets. Rank each, add the ranks, and favour the lowest total.
Can I use the magic formula with the Five Criteria?
Yes. Use it to generate ideas, then check each company for five years of high returns, a moat, aligned management, a sound balance sheet and a reasonable price.
Further reading
The book mentioned in this guide
Affiliate links: book links go to Amazon. As an Amazon Associate, Gingernomics earns from qualifying purchases. It doesn't change the price you pay or which books we list.
Advanced
You Can Be a Stock Market GeniusJoel GreenblattSpecial situations: spin-offs and restructurings.
See the book (affiliate link, opens in a new tab) Our summary
Put this into practice
Try it on a real company, with free tools
Ready for the full model? See the Free Cash Flow Valuation Model
