Stock Profit Tax Calculator 2025 β Capital Gains on Stocks
Calculate taxes on stock sale profits including capital gains tax and dividend tax. Compare FIFO, LIFO, and specific identification cost basis methods.
$
$
$
$
$
Added to cost basis $0
Total Tax Owed
$0
Capital Gains Tax
$0
Dividend Tax
$0
Net After-Tax Profit
Stock Tax Breakdown
How to Use This Stock Profit Tax Calculator
Enter the number of shares sold, your purchase price per share (cost basis), and the sale price per share. Select whether you held the shares short-term or long-term. If you received dividends, enter the annual amount and whether they are qualified or ordinary.
Any commissions paid on the buy or sell side are added to your cost basis, reducing the taxable gain.
The Formula
Cost Basis = (Buy Price Γ Shares) + Commissions
Proceeds = Sell Price Γ Shares
Capital Gain = Proceeds β Cost Basis
CG Tax = Gain Γ Rate (short-term: marginal rate; long-term: 0%/15%/20%)
Dividend Tax = Dividends Γ Rate (qualified: 0%/15%/20%; ordinary: marginal rate)
Proceeds = Sell Price Γ Shares
Capital Gain = Proceeds β Cost Basis
CG Tax = Gain Γ Rate (short-term: marginal rate; long-term: 0%/15%/20%)
Dividend Tax = Dividends Γ Rate (qualified: 0%/15%/20%; ordinary: marginal rate)
Example
100 shares of AAPL, bought at $50, sold at $120, held 2 years, $75K other income (single):
Cost basis: 100 Γ $50 = $5,000 | Proceeds: 100 Γ $120 = $12,000
Capital gain: $7,000 (long-term) | LTCG rate: 15%
CG tax: $7,000 Γ 15% = $1,050 | Net profit: $5,950
Cost basis: 100 Γ $50 = $5,000 | Proceeds: 100 Γ $120 = $12,000
Capital gain: $7,000 (long-term) | LTCG rate: 15%
CG tax: $7,000 Γ 15% = $1,050 | Net profit: $5,950
Extended
Cost Basis Methods Comparison
Compare FIFO, LIFO, and specific identification to find the lowest-tax exit strategy
If you bought shares in multiple lots at different prices, compare cost basis methods to find the most tax-efficient way to sell.
Enter Your Share Lots (up to 4)
$
| Cost Basis Method | Cost Basis Used | Capital Gain | Est. Tax | Net Proceeds |
|---|
Frequently Asked Questions
How are stock profits taxed?
Stock profits (capital gains) are taxed based on how long you held the stock. Short-term gains (held 1 year or less) are taxed at ordinary income rates (10%β37%). Long-term gains (held more than 1 year) receive preferential rates of 0%, 15%, or 20%. Dividends are taxed as either qualified (same rates as LTCG) or ordinary income.
What are the different stock cost basis methods?
The four main cost basis methods are: (1) FIFO β first shares purchased are treated as first sold, often creates larger gains in rising markets; (2) LIFO β last shares purchased sold first, can minimize gains short-term; (3) Specific Identification β you specify which shares to sell for maximum tax control; (4) Average Cost β average price across all shares, only available for mutual funds. Specific identification generally gives the most tax flexibility.
Are dividends taxed differently than capital gains?
Qualified dividends (from domestic corporations or qualifying foreign companies, held for the required period) are taxed at the same 0%, 15%, or 20% rates as long-term capital gains. Ordinary dividends are taxed at your regular marginal income tax rates. Your 1099-DIV distinguishes between qualified (box 1b) and ordinary (box 1a) dividends.
What is the wash sale rule?
The wash sale rule prevents you from claiming a tax loss if you buy "substantially identical" securities within 30 days before or after selling at a loss. If you violate the wash sale rule, the loss is disallowed β it gets added to the cost basis of the replacement shares instead. This rule applies to stocks, ETFs, and options on the same security.
How does selling employer stock (RSUs/ESPPs) work for taxes?
For RSUs, income tax is withheld at vesting on the fair market value. When you sell, you pay capital gains tax on the appreciation since vesting. For ESPPs, the discount element is ordinary income; the remaining gain may qualify for long-term rates if held long enough. Your broker should provide a Form 3922 or adjusted 1099-B β always verify the cost basis is correct.