Work out basic earnings per share from net income, preferred dividends and weighted average shares, and the P/E ratio from the share price.
Estimates for planning, not financial, tax or legal advice. Figures use US rules unless the page says otherwise.
The EPS formula
Basic EPS = (net income − preferred dividends) ÷ weighted average common shares outstanding
P/E ratio = share price ÷ EPS
Preferred dividends come out first because that money belongs to preferred shareholders. Shares are averaged over the year, weighted by how many months each block was outstanding, so a big share sale in December doesn't distort the whole year. The SEC's guide to financial statements describes EPS as net income divided by shares outstanding, and the P/E ratio as share price divided by EPS.
Worked example
A company earns $2,500,000 and pays $250,000 of preferred dividends, leaving $2,250,000 for common shareholders. It started the year with 1,000,000 shares, issued 300,000 more that were outstanding for 6 months, and bought back 100,000 three months before year-end. Weighted shares = 1,000,000 + 300,000 × 6/12 − 100,000 × 3/12 = 1,000,000 + 150,000 − 25,000 = 1,125,000. Basic EPS = 2,250,000 ÷ 1,125,000 = $2.00. At a $30 share price, P/E = 30 ÷ 2 = 15.
Limitations
- This is basic EPS. Diluted EPS also counts shares that could be created from options, warrants and convertible securities, so it's the same or lower.
- Stock splits and stock dividends are applied to all periods as if they had always happened, rather than weighted by date.
- Only cumulative preferred dividends for the period, or those declared, are subtracted.
- P/E isn't meaningful when EPS is zero or negative.
Sources
How we checked this
Before every update, this calculator is run in a real browser with these known answers, and it must match all of them:
- ($2.5M − $250k preferred) ÷ 1,125,000 shares = $2.00 EPS ✓
- $30 share price ÷ $2.00 EPS = P/E 15 ✓
- 1,000,000 + 300,000 × 6/12 − 100,000 × 3/12 = 1,125,000 weighted shares ✓
- Edge: a net loss gives negative EPS and no P/E ✓
- Edge: 0 weighted shares is rejected ✓
Last checked October 26, 2026. Spotted something wrong? The math is done in your browser with the formula shown on this page, so you can check any result by hand.
Questions people ask
How do you calculate earnings per share?
Subtract preferred dividends from net income and divide by the weighted average number of common shares. ($2.5M − $250k) ÷ 1,125,000 = $2.00.
Why use weighted average shares?
Because the share count changes during the year. Weighting each block by the months it was outstanding matches shares to the period the earnings were made.
What is the difference between basic and diluted EPS?
Diluted EPS adds shares that options, warrants and convertibles could create, so it shows the worst case for existing shareholders.
How do you calculate the P/E ratio?
Divide the share price by earnings per share. A $30 stock with $2.00 of EPS has a P/E of 15.
Can EPS be negative?
Yes. A net loss gives negative EPS, and the P/E ratio isn't meaningful then.