Price to Earnings (P/E) Ratio Calculator

P/E ratio25.00
Earnings yield4.00%
How this was calculated
  1. Share price is $185.50 and trailing EPS is $7.42.
  2. P/E = $185.50 / $7.42 = 25.00.
  3. Earnings yield is the inverse view: $7.42 / $185.50 = 4.00%.

Our price to earnings ratio calculator takes a company's share price and its earnings per share, or EPS, and returns the P/E ratio along with the earnings yield. The P/E ratio equals share price divided by earnings per share, while the earnings yield is the inverse — EPS divided by price — expressed as a percentage. For example, a share price of $185.50 with EPS of $7.42 gives a P/E of 25.00 and an earnings yield of 4.00%. A share price of $312.75 with EPS of $9.75 gives a P/E of 32.08 and an earnings yield of 3.12%. You can also derive EPS yourself: net income of $920,000,000 over 115,000,000 shares gives EPS of $8.00, so a $48.00 share price gives a P/E of 6.00 and an earnings yield of 16.67%. Note that the P/E is meaningless when EPS is zero or negative, so loss-making companies are quoted as having no P/E.

The share price divided by earnings per share method is the accepted standard because it directly compares what investors pay for each dollar of profit a company generates. Trailing P/E uses the last twelve months of reported earnings, while forward P/E uses analyst forecasts, so the two can differ widely for the same stock. This page shows the formula, step-by-step workings, worked examples, and sources so you can verify every result yourself.

Worked examples

A market-average multiple

Primary result: 25.00 — $185.50 buys $7.42 of annual earnings, an earnings yield of 4.00%. (Share price & EPS · 185.5 $ · 7.42 $ · 920000000 $ · 115000000)

P/E ratio25.00
Earnings yield4.00%

EPS built from the accounts

Primary result: 6.00 — $920,000,000 over 115,000,000 shares is $8.00 of EPS, so a $48.00 share is cheap on earnings. (Price, net income & shares outstanding · 48 $ · 7.42 $ · 920000000 $ · 115000000)

P/E ratio6.00
Earnings per share$8.00
Earnings yield16.67%

Priced for growth

Primary result: 32.08 — investors pay up for expected earnings growth, and the earnings yield thins to 3.12%. (Share price & EPS · 312.75 $ · 9.75 $ · 920000000 $ · 115000000)

P/E ratio32.08
Earnings yield3.12%

What the P/E ratio tells you

The P/E ratio tells you how many dollars you pay for each dollar of a company's earnings. It is calculated as share price divided by earnings per share, and the earnings yield is simply the inverse — EPS divided by price, expressed as a percentage. A P/E of 25.00, for example, means you are paying $25 for every $1 of annual earnings, and the earnings yield is 4.00%. Our price to earnings ratio calculator works through this math so you can see both figures side by side.

Think of the P/E as a valuation shorthand, not a quality score. A lower ratio can mean a stock looks cheap relative to its current profits, while a higher ratio can mean investors expect faster growth and have bid the price up. But the number alone does not tell you whether a company is well run, whether its earnings are sustainable, or whether the stock is truly a bargain. Consider three verified examples: a share price of $185.50 with EPS of $7.42 gives a P/E of 25.00 and an earnings yield of 4.00%; net income of $920,000,000 spread over 115,000,000 shares gives EPS of $8.00, so a $48.00 share price gives a P/E of 6.00 and an earnings yield of 16.67%; and a share price of $312.75 with EPS of $9.75 gives a P/E of 32.08 and an earnings yield of 3.12%.

The P/E is meaningless when EPS is zero or negative. Loss-making companies are quoted as having no P/E, because dividing a positive price by zero or a negative number does not produce a useful comparison. In those cases, investors usually look at other metrics — revenue growth, cash flow, or forward earnings expectations — rather than forcing a ratio that cannot be interpreted.

Finally, remember that trailing P/E and forward P/E can differ widely for the same stock. Trailing P/E uses the last twelve months of reported earnings, so it reflects what already happened. Forward P/E uses analyst forecasts, so it reflects what investors expect to happen next. A company with a high trailing P/E might look expensive until you check the forward figure, or vice versa. Always confirm which version a source is reporting before you draw conclusions.

A P/E ratio tells you what you are paying for earnings — not whether the company is worth buying. Pair it with earnings yield, growth expectations, and a check on whether the figure is trailing or forward before making any decision.

Two routes to the same number

A price to earnings ratio calculator can take either of two inputs to reach the same result. The first route is direct: you enter the current share price and the published earnings per share, and the tool divides the price by the EPS. The second route is useful when a company has not yet stated EPS outright, or when you want to verify a reported figure yourself. You provide net income and the share count, the calculator divides income by shares to build EPS, and then divides price by that EPS. Both paths apply the same formula: P/E ratio = share price / earnings per share. The earnings yield is simply the inverse, EPS / price, expressed as a percentage.

The verified cases show how each route works in practice. Take the first route: a share price of $185.50 with EPS of $7.42 gives a P/E of 25.00 and an earnings yield of 4.00%. The same calculator accepts the second route as well: net income of $920,000,000 over 115,000,000 shares gives EPS of $8.00, so a $48.00 share price gives a P/E of 6.00 and an earnings yield of 16.67%. A third verified example, a share price of $312.75 with EPS of $9.75, produces a P/E of 32.08 and an earnings yield of 3.12%. The math is identical in each case; only the starting inputs differ.

One boundary matters before you enter any numbers. The P/E is meaningless when EPS is zero or negative, because dividing by zero is undefined and dividing by a negative number turns the ratio negative in a way that has no useful interpretation. Loss-making companies are quoted as having no P/E, and a reliable calculator will return no result rather than a misleading figure. If you see a blank or flagged output for a company that lost money in the period, that is the correct response.

Finally, note which earnings the calculator is using. Trailing P/E uses the last twelve months of reported earnings, so it reflects what the company has already done. Forward P/E uses analyst forecasts, so the two can differ widely for the same stock when expectations diverge from recent results. Always confirm which figure your source provides before you compare ratios across companies or time periods.

Worked examples

The best way to understand how a price to earnings ratio calculator works is to walk through real numbers. The three cases below cover a market-average stock, a cheap value play, and a growth-priced name. Each example applies the same formula: P/E ratio equals share price divided by earnings per share. The earnings yield is the inverse, EPS divided by price, expressed as a percentage.

The first example represents a stock trading at typical market levels. A share price of $185.50 with EPS of $7.42 produces a P/E of 25.00 and an earnings yield of 4.00%. An investor buying at that price pays twenty-five dollars for every one dollar of annual earnings. The second example shows a stock the market views as cheap. Net income of $920,000,000 spread over 115,000,000 shares gives EPS of $8.00. At a share price of $48.00, the P/E falls to 6.00 and the earnings yield rises to 16.67%. Here the buyer pays only six dollars per dollar of earnings, and the higher yield reflects the lower valuation.

The third example reflects a growth-priced stock. A share price of $312.75 with EPS of $9.75 yields a P/E of 32.08 and an earnings yield of 3.12%. Investors accept a high multiple because they expect future earnings to rise sharply. This is where the distinction between trailing and forward P/E matters. Trailing P/E uses the last twelve months of reported earnings, while forward P/E uses analyst forecasts, so the two can differ widely for the same stock.

One caution applies to every example: the P/E is meaningless when EPS is zero or negative. Loss-making companies are quoted as having no P/E, and the calculator returns no usable ratio for them. In those cases investors rely on other measures, but for profitable companies the P/E remains one of the quickest ways to gauge whether a stock looks expensive, cheap, or fairly priced relative to its current earnings.

Share PriceEPSP/E RatioEarnings Yield
$185.50$7.4225.004.00%
$48.00$8.006.0016.67%
$312.75$9.7532.083.12%

Earnings yield: the P/E turned upside down

The earnings yield is simply the P/E ratio turned upside down. Instead of dividing share price by earnings per share, you divide earnings per share by price and express the result as a percentage. A price to earnings ratio calculator can show both figures side by side, because each tells you something useful from the opposite direction. The P/E tells you how many years of earnings you are paying for one share; the earnings yield tells you what percentage of your purchase price the company earns each year.

Consider a stock trading at $185.50 with earnings per share of $7.42. The P/E works out to 25.00, and the earnings yield is 4.00%. Flip to a different company: net income of $920,000,000 spread over 115,000,000 shares gives EPS of $8.00, and at a share price of $48.00 the P/E is 6.00 while the earnings yield is 16.67%. A third stock priced at $312.75 with EPS of $9.75 carries a P/E of 32.08 and an earnings yield of 3.12%. The pattern is straightforward — a high P/E means a low earnings yield, and a low P/E means a high earnings yield.

Expressing the result as a percentage makes it directly comparable with bond yields. If a company's earnings yield is 4.00% and a Treasury bond yields 5.00%, you can ask whether the extra risk of holding stock is worth the lower current yield. Investors who focus on income often prefer stocks whose earnings yield meets or exceeds prevailing bond yields, while those focused on growth may accept a lower yield if they expect earnings to rise.

One important limitation applies to both measures: the P/E is meaningless when EPS is zero or negative. Loss-making companies are quoted as having no P/E, and the earnings yield cannot be calculated for them either. Also keep in mind whether the figure you are using is trailing or forward. Trailing P/E uses the last twelve months of reported earnings, while forward P/E uses analyst forecasts, so the two can differ widely for the same stock — and so can their corresponding earnings yields.

Trailing versus forward P/E

The P/E ratio you see quoted for a stock can vary from one data provider to another, and the main reason is the earnings figure used in the calculation. The formula itself is simple: P/E ratio equals share price divided by earnings per share. The earnings yield is the inverse, EPS divided by price, expressed as a percentage. Because share prices change constantly but earnings are reported only periodically, the timing of the earnings number matters a great deal.

Trailing P/E uses the last twelve months of reported earnings. This figure is based on actual results the company has already disclosed, so it is grounded in audited financial statements. A price to earnings ratio calculator that uses trailing earnings will give you a number you can verify against the company's most recent annual or quarterly filings. For example, a share price of $185.50 with trailing EPS of $7.42 gives a P/E of 25.00 and an earnings yield of 4.00%. The same approach applies across companies of very different sizes: net income of $920,000,000 over 115,000,000 shares gives EPS of $8.00, so a $48.00 share price gives a P/E of 6.00 and an earnings yield of 16.67%.

Forward P/E uses analyst forecasts instead of reported earnings. Instead of looking at what the company earned over the past year, it divides the current share price by the consensus estimate of what the company will earn over the coming year. Because forecasts reflect expectations about future growth, forward P/E can differ widely from trailing P/E for the same stock. A company expected to grow rapidly may have a forward P/E well below its trailing P/E, since projected earnings are higher than past earnings. A company facing declining profits may show the opposite pattern. At a share price of $312.75 with forecast EPS of $9.75, the forward P/E is 32.08 and the earnings yield is 3.12%.

This difference explains why two financial websites can show different P/E figures for the same stock on the same day. One may be reporting trailing P/E based on the most recent reported earnings, while another may be reporting forward P/E based on analyst estimates. Neither figure is wrong, but they answer different questions. Trailing P/E asks what investors are paying for earnings the company has already produced. Forward P/E asks what investors are paying for earnings the company is expected to produce. When you use a price to earnings ratio calculator, check which earnings figure it relies on so you can compare results consistently.

The P/E is meaningless when EPS is zero or negative. Loss-making companies are quoted as having no P/E, because dividing a positive share price by zero or a negative number does not produce a useful result.

Limits of the P/E ratio

The price to earnings ratio calculator is a quick way to compare what investors pay for a dollar of profit, but the number it returns is not always meaningful. The clearest failure case is a company whose earnings per share is zero or negative. Because the P/E ratio divides share price by EPS, a loss-making company produces a result that cannot be interpreted, so such stocks are quoted as having no P/E at all. A business that earned nothing over the past year may still have a high share price based on growth expectations, but no trailing P/E can capture that.

Even when earnings are positive, one-off items can distort the ratio. A company that sells a division or books a large tax benefit may report a single quarter or full year of inflated profit, which lowers its trailing P/E and makes the stock look cheap. The trailing P/E uses the last twelve months of reported earnings, while the forward P/E relies on analyst forecasts, so the two can differ widely for the same stock. A trailing ratio of 25.00, as in the case of a $185.50 share price with EPS of $7.42, may look high next to a forward ratio of 15.00 if analysts expect profit to rise. Without knowing which earnings period the figure uses, an investor cannot judge whether the stock is expensive or fairly valued.

Differences in accounting make cross-company comparisons harder than they appear. Two firms in the same industry can report different EPS for the same underlying business because of choices about depreciation schedules, stock-based compensation, or goodwill write-downs. A P/E of 6.00 derived from a $48.00 share price and EPS of $8.00 may reflect genuinely strong earnings, but it may also reflect aggressive assumptions about one-time gains or deferred costs. Likewise, a P/E of 32.08 from a $312.75 share price and EPS of $9.75 could signal overvaluation, or it could reflect conservative accounting that depresses reported profit. The ratio alone does not reveal which is the case.

Sector context matters more than any single threshold. A P/E that looks high for a utility may look low for a software company, because investors in different industries accept different growth rates, risk levels, and profit cycles. The earnings yield, which is the inverse of the P/E and expressed as a percentage, helps frame this: a P/E of 6.00 gives an earnings yield of 16.67%, while a P/E of 32.08 gives just 3.12%. Whether those yields are attractive depends on what the sector, interest rates, and the company's own history justify. No universal P/E mark separates cheap from expensive.

FAQs

How is the P/E ratio calculated?

The P/E ratio is calculated by dividing the share price by earnings per share. For example, $185.50 divided by $7.42 equals 25.00 in the verified example. This tells you how many dollars you are paying for each dollar of the company's annual earnings.

What is a good P/E ratio?

It depends on sector and growth. Verified examples span from 6.00, considered cheap, to 32.08, considered growth-priced. A P/E of 25.00 sits near long-run market averages. What counts as good varies by industry, so compare companies within the same sector rather than across unrelated ones.

What is earnings yield?

Earnings yield is EPS divided by price, making it the inverse of the P/E ratio. A P/E of 25.00 corresponds to a 4.00% earnings yield. It lets you compare a stock's earnings power directly with bond yields or other investment returns on a percentage basis.

Why do some stocks show no P/E?

Some stocks show no P/E because EPS is zero or negative, making the ratio meaningless. When a company has no profit or is losing money, dividing price by earnings produces no useful figure. The calculator reports 'not meaningful' in that case, so you know the result cannot guide your investment decision.

What is the difference between trailing and forward P/E?

Trailing P/E uses reported earnings from the last twelve months, reflecting what the company has already earned. Forward P/E uses forecast earnings, reflecting what analysts expect the company to earn going forward. Trailing looks backward at actual results, while forward looks ahead at projected future profits.

Can I compute P/E from net income directly?

Yes. Divide net income by shares outstanding to get EPS first, then divide price by that EPS. In the verified example, $920,000,000 over 115,000,000 shares equals $8.00 of EPS. Once you have EPS, use the share price to compute the P/E ratio the same way as always.

Sources

Related calculators

Earnings Per Share (EPS) Calculator
Basic and diluted EPS from net income, preferred dividends and the weighted-average share count — the per-share profit figure behind the P/E ratio.
Dividend Yield Calculator
Dividend yield from share price and annual dividend, your total yearly and monthly dividend income, and your yield on cost at the price you actually paid.
Book Value Per Share Calculator
The accounting value behind each common share — total equity minus preferred equity, divided by the share count, with the price-to-book ratio when you add a market price.
Enterprise Value Calculator
What a buyer effectively pays for the whole business — market cap plus debt, preferred stock and minority interest, minus the cash that comes with the deal, with EV/EBITDA alongside.