Some of history's greatest investors have been self-described "value investors," including Benjamin Graham, Warren Buffett, and Joel Greenblatt, whose track records have left the market in the dust. For those who have the interest and time, value investing can be a wonderful tool to build wealth for you and your family.

There are many nuances to value investing, not all of which we could possibly explore in a single article, or even a single book. That said, there are basic tenets of value investing that can be applied universally. In this article, we'll take you through these steps one by one:

  1. Prepare to invest.
  2. Understand what value investing is.
  3. Learn why value investing works. 
  4. Calculate a stock's value using different metrics.
  5. Find the intrinsic value and margin of safety you'll need to invest confidently.
  6. Understand the difference between a good value and a value trap.
  7. Practice patience and tenacity. 
A hand draws a scale with "Price" on one side and "Value" on the other

Value investing involves buying a stock at a price below its intrinsic value. Image source: Getty Images.

In a moment, we will take a closer look at each of these steps and what they entail, but first...

Prepare to invest

To fully take control of your financial future, there are many elements you must get in order. You should check nearly all of them off your to-do list before you start testing your mettle against the stock market.

The journey begins with seemingly simple steps that, in reality, can be the hardest to take. This includes getting expenses under control and establishing a budget so you can make sure you aren't spending more than you earn. After navigating your monthly expenses, it is important to set up an emergency savings fund so you don't have to go into more debt every time one of life's unexpected crises hits. Finally, pay off your high-interest debt, the interest of which will derail any dreams you have of building wealth.

If you're already out of debt, make sure you're earning at least any employer match offered by your company's 401(k) plan, and start saving for retirement. If your employer doesn't offer a 401(k), you should look into opening an IRA, or Individual Retirement Account. Opening a brokerage account for all of your investment needs can seem complicated at first. (Luckily, we've got a step-by-step, easy-to-understand guide for how to open a brokerage account.)

If you're spending less than you earn, are out of debt, possess a fully funded emergency savings account, and are already saving for retirement ... congratulations! You're well on your way to achieving the financial future of your dreams. After all of that, if you're willing to take the time and effort to learn about how to become a value investor in an attempt to score outsized gains in the stock market, read on.

What is value investing?

Value investing involves determining the intrinsic value -- the true, inherent worth of an asset -- and buying it at a level that represents a substantial discount to that price. The gap between a stock's intrinsic value and the price it is currently selling for is known as the margin of safety. The greater the margin of safety, the more an investor's projections can be off while still profitably gaining from an investment in the shares of the company being evaluated. 

This chart, made by Motley Fool contributor Daniel Sparks and used here with permission, illustrates this concept.

A graph illustrating concept of the margin of safety in value investing.

Value investors seeks to buy stocks at a discount to their intrinsic value. This gap between the price and intrinsic value is often referred to as the margin of safety. Image source: Daniel Sparks. Used with permission.

I believe there are a lot of misconceptions among investors about what value investing really is. Therefore, it can be helpful to ensure that you understand what value investing is and is not. It is not searching for stocks with low price-to-earnings ratios and blindly buying the stocks that make that first cut. Instead, value investors employ a series of metrics and ratios -- discussed in detail below -- to help them determine a stock's intrinsic value and a sufficient margin of safety.  

Of course, this can be applied to other types of investments, too. For instance, famed investor Joel Greenblatt described in his book, The Little Book That Beats The Market, how his in-laws would drive to estate sales in the country looking for pieces of art selling at a price substantially below what they could fetch in the city. They were able to find many pieces of art this way, because they always knew the prices that various artists' work were currently going for.

Value investing in stocks often means looking for mispriced shares in out-of-the-way places. This can include looking at companies in out-of-favor sectors, businesses in frowned-upon industries, companies that are going through some type of scandal, or stocks currently enduring a bear market. Unpopular sectors and companies are often treasure troves for the successful value investor, requiring the possession of both a long-term approach and a contrarian mindset. Regardless of where the investments come from, though, value investing is the art and science of identifying stocks priced below their actual worth.

Why value investing works

Many claim that value investing cannot possibly work because it's impossible to beat the market, and that the market is always fairly valued because all information known about a stock is perfectly reflected in its share price at any given point in time. This theory is known as the efficient market hypothesis. Proponents of this theory suggest that because the market is fairly valued, it is advisable to just invest money in a low-cost index fund, guaranteeing a match of the market's returns.

Instead of relying on the market's valuation of a stock, value investors believe the market consistently prices shares of companies irrationally based on the prevalent economic mood of the day. As the father of value investing, Benjamin Graham, once wrote in his classic The Intelligent Investor:

Imagine that in some private business you own a small share that cost you $1,000. One of your partners, named Mr. Market, is very obliging indeed. Every day he tells you what he thinks your interest is worth and furthermore offers either to buy you out or to sell you an additional interest on that basis. Sometimes his idea of value appears plausible and justified by business developments and prospects as you know them. Often, on the other hand, Mr. Market lets his enthusiasm or his fears run away with him, and the value he proposes seems to you a little short of silly.

By exploiting Mr. Market's many moods (e.g., buying low and selling high), value investors believe that beating the market is not a matter of chance -- as the efficient market hypothesis advocates would have you believe -- but the result of due diligence.

How to value stocks

There are many different ways to value stocks. The more of these valuation methods investors are familiar with, the more tools are at their disposal. While it's not the sole determinant of a good value investment, the cornerstone of valuation metrics is the P/E ratio, which stands for price-to-earnings ratio. This formula is calculated by dividing a company's stock price by its earnings per share (EPS). Earnings per share is essentially the company's net income divided by the number of its shares outstanding, the number of a company's shares of common stock that investors own.

How to calculate the P/E ratio

Let's briefly walk through a real-life example using Facebook. The specific numbers will change over time; the underlying math won't. 

Suppose that over the trailing 12 months, which you'll see abbreviated as TTM, Facebook reported $7.23 in EPS. And let's also suppose that the company's current share price is $177.78. Using these figures, we can calculate the company's P/E ratio this way:

177.78 (share price) / 7.23 (EPS over TTM) = 24.52 trailing P/E

With a P/E ratio of close to 25, value investors looking at P/E ratios alone might be turned off to investing in Facebook shares at this time, especially if that metric is higher than the P/Es for Facebook's peers, or the S&P 500 as a whole. However, value investors using different methods might come to a different conclusion.

For instance, in Warren Buffett's 1992 letter to shareholders, he commented that value investing and growth investing were two sides of the same coin. Buffett said, "In our opinion, the two approaches are joined at the hip: Growth is always a component in the calculation of value, constituting a variable whose importance can range from negligible to enormous and whose impact can be negative as well as positive."

How to calculate a forward P/E

One common method to calculate for a company's growth is the forward P/E ratio. The forward P/E ratio is found by simply using the company's projected EPS to calculate its future P/E ratio. If the consensus estimate among analysts for Facebook's EPS for the current fiscal year is $7.66, then Facebook's forward P/E ratio is:

177.78 (share price) / 7.66 (projected EPS for current year) = 23.21 forward P/E

So, already, shares are beginning to look a little cheaper. And if the EPS estimate among analysts for the year after that is $9.33, then Facebook's forward P/E ratio for that year is:

177.78 (share price) / 9.33 (projected EPS for next fiscal year) = 19.05 forward P/E

Suddenly, Facebook's shares are beginning to look a lot cheaper! Obviously, the further forward you look, the more uncertainty is baked into analysts' predictions, but using the forward P/E ratio is a way for investors to look at a company's share price relative to the growth in earnings the company is expected to see.

How to calculate PEG and price-to-sales ratios

Along the same lines is a company's PEG ratio, which stands for price-earnings-growth ratio. The PEG ratio uses the company's P/E ratio in conjunction with its projected earnings growth rate to value a company and is calculated by dividing the P/E ratio by the expected EPS growth rate. All things being equal, a PEG ratio less than 1.0 is considered a good value, while a PEG ratio over 1.0 could require further investigation before an investment is made. Again, though, be wary that the further out EPS estimates go, the more guesswork comes into play. 

Another valuation metric investors often use is the price-to-sales ratio, or P/S ratio. The P/S ratio is calculated by dividing a company's market cap -- determined by calculating the company's number of shares outstanding by its share price -- by its annual revenue. This tool is especially helpful to compare companies in the same industry, because they should share common margins, as well as companies that are not yet profitable and thus do not yet have EPS figures with which to find a P/E ratio.

How to calculate free cash flow

Many investors now prefer to look at a company's free cash flow over its earnings to know how much cash a company really has left over at the end of each year. Free cash flow equals cash flow from operations minus capital expenditures. Capital expenditures, commonly referred to as capex, are money the company uses to invest in physical assets it needs to improve its value or increase its productivity. This could mean anything from data centers and factories to new vehicles and office computers. You can find the figures you'll need to calculate free cash flow on a company's cash flow statement.

To value a company using free cash flow, investors can use its price-to-free cash flow ratio (P/FCF). As an added bonus, the formula is fairly simple to solve.

Price-to-free cash flow = Market cap / Free cash flow

So, for instance, if a company has a market cap of $40 billion and free cash flow of $2 billion, it sports a price-to-free cash flow ratio of 20 ($40 billion / $2 billion = 20).

How to calculate book value and the P/B ratio

The price-to-book ratio is another metric that can be useful for valuing stocks. The book value is found by subtracting a company's liabilities from its assets. Dividing the book value by the number of outstanding shares for a company finds the company's book value per share. Finally, dividing the share price by the book value per share gives investors the price-to-book ratio.

Assets - Liabilities = Book value

Book value / Outstanding shares = Book value per share

Share price / Book value per share = Price-to-book ratio

Decades ago, this was probably value investors' favorite metric to look at when determining if a stock was over- or undervalued. It works great for companies that own factories, heavy machinery, or holds lots of assets on balance sheets. In other words, it was almost the perfect tool for finding value in an economy featuring industrial and financial titans. Unfortunately, it is not nearly as useful for asset-light business models, such as software-as-a-service (SaaS) or many other tech companies. Given today's economy, this formula proves most effective for valuing banks and industrial companies that carry a number of assets and liabilities on their balance sheets. 

Finding intrinsic value and the right margin of safety

Unfortunately, there is no one universally accepted way to find the intrinsic value of a stock. Many investors focus on their favorite valuation metrics, as discussed above, and compare a company's metrics to industry peers or even the broader S&P 500 index. Others use more involved methods, such as the discounted cash-flow analysis, where projected future cash flow is discounted back to the present. Others use intangible factors as well when determining intrinsic value. Many use a combination of the above.

Two tips might help you, here:

  • First, find a method you're comfortable with. If you're not satisfied with how you're determining intrinsic value, you'll be prone to abandon your approach when things look bleakest, which is often the worst time to sell!
  • Second, don't rely on any one factor -- use several. Often one metric that works well in one industry won't work nearly as well in another. Other times, reliable factors in a bull market won't work in a bear market. Stay flexible.

Determining the right margin of safety before pulling the trigger on an investment is also not an exact science. Just remember that the wider the margin of safety, the more you can be wrong and still make a decent return on an investment. 

For some investors, this means looking for a stock price 25% below what they calculate the intrinsic value to be. For others, this might mean determining that a stock can still achieve a decent rate of return if earnings grow at 10%, though they are projected to grow by 25%. Again, the most important thing is coming up with a disciplined plan you are comfortable with. 

Avoid value traps!

Now you know what value investing is, and you understand why it works. Let's say you begin to look at stocks using a variety of different valuation methods, and you find one that looks really cheap. In fact, it almost looks too good to be true! Maybe its P/E ratio is half that of its industry peers, or maybe its PEG ratio clears the 1.0 mark with ease. Before you make a sizable investment, take a step back and consider if the stock is a value ... or value trap! (Cue ominous music.)

A value trap is a company whose shares look cheap upon an initial inspection but, in reality, are not. There are lots of reasons this might be the case. For example, consider an oil-drilling company. If the price of oil spikes, the company's shares might suddenly look cheap, as drilling and exploration demand rises, leading to increased output and higher profits. This might give the company an artificially low P/E ratio. However, if the price of oil were to suddenly start falling again, earnings would drop, and what once looked like a P/E from the bargain basement might suddenly seem expensive compared to the general stock market. 

Other common examples of value traps include pharmaceutical companies with drug patents that are set to expire soon, or tech companies with products and services that are becoming commoditized by competition. Even the world's greatest investors have fallen for value traps; one of Warren Buffett's biggest mistakes was his ill-timed investment in IBM, which Buffett unwisely based on the company's past glories rather than its present difficulties.

The key to winning at value investing

Value investing often requires a contrarian mindset, meaning that some of the best values in the stock market are found in unpopular places. For instance, while most investors began panicking that malls were dying, some department-store stocks fell to near-absurd levels -- prices that in some cases have already led to a department-store stock comeback! While this sounds easy in practice, it is extremely difficult to remain resolute in real life. You can look at the numbers all day and believe in your heart of hearts that a business's shares are undervalued, but it can be awfully hard to hold on as the stock price keeps a downward trajectory while headlines are screaming doom and gloom.

In the Motley Fool Investment Guide, the Gardner brothers warn about letting your emotions get the best of you. They write:

As we've warned over the years, you are your own worst enemy. Those are the six most important words in investing. Shady financial advisors, incompetent CEOs, and overpriced mutual funds don't harm your returns a fraction of the amount that your own behavior does. That's because successful investing has far more to do with how you act than with what you know. Traits like good temperament, patience, levelheadedness, and the ability to overcome biases are more integral to doing well in the market than anything you might learn in a classroom.

Unfortunately, I have not always shown good temperament, patience, and levelheadedness in my own investing history. For instance, consider the time I shared why I decided to sell Michael Kors. This was after buying shares at just a little above $40 in mid-2015, when the company's stock had taken a precipitous fall from its peak. During that time, I argued that Michael Kors was too cheap by looking at several different valuation techniques and comparing it to industry peers. I was convinced the market would eventually prove me right.

Yet the waiting grated on me. While these shares languished, other companies took off. Eventually, I lost faith in management for a variety of reasons and sold my entire position in the low-$30s. Almost immediately after selling my shares, the stock price rocketed upward and shares in the lifestyle retailer have not looked back since. After I sold my shares, Michael Kors stock began rapidly appreciating, almost doubling within a year!

On the flip side, there are numerous successful value investing stories stemming from having patience and holding during lean times. Taking just one recent example, in early 2015, American Express shareholders learned that AmEx lost its exclusive credit-card deal with Costco Wholesale locations. In the following months, Amex lost almost 50% of its market-cap value. Yet far from being a moment to panic, savvy investors might have seen an opportunity to buy AmEx for outsized gains. Within three years of its lowest point, American Express had almost doubled and reached new all-time highs.

Selling at lows while negative sentiment is at its highest will guarantee frustration and permanent loss of capital. It can be hard to wait while your thesis plays out, but patience is absolutely necessary for value investors who want to beat the market.

Of course, value investing is more than a waiting game. Investors must remain diligent in staying up to date on a company to ensure their thesis is proceeding as planned. This means paying attention to the company's business performance -- not its stock price.

The big takeaway

Value investing is not easy. It requires time and dedication to the craft. It will often mean looking and feeling small-f foolish while you wait for an investment thesis to play out. If this doesn't sound like it's for you, investing in passive index funds is a perfectly suitable alternative.

That said, for investors who enjoy the hunt of looking for undervalued assets -- and beating the market at its own game -- value investing can be richly rewarding in more ways than one. By following this simple guide, investors can be well on their way to understanding how value investing can beat the market.