Enter shares, buy and sell prices and commissions to see the profit or loss, the percentage return, the break-even sell price and an estimate of tax on the gain
Enter the number of shares, the price you paid and the price you sold at (or are considering), plus any commission on each trade and the tax rate you expect on the gain. The calculator shows the cost basis, the sale proceeds, the profit or loss in dollars and as a percentage, and the sell price you need to break even after fees.
Cost basis = shares × buy price + buy commission. Proceeds = shares × sell price − sell commission. Profit = proceeds − cost basis, and return = profit ÷ cost basis. Buying 100 shares at $50 and selling at $65 with $5 commission each way: basis $5,005, proceeds $6,495, profit $1,490, a 29.77% return. Break-even after both commissions is $50.10 a share. Selling at $45 instead would be a $-510 loss.
| Sell price | Profit / loss | Return |
|---|---|---|
| $40 | $-1,010 | -20.18% |
| $45 | $-510 | -10.19% |
| $50 | $-10 | -0.20% |
| $55 | $490 | 9.79% |
| $65 | $1,490 | 29.77% |
| $75 | $2,490 | 49.75% |
IRS Topic 409: shares held more than one year produce a long-term gain or loss; one year or less is short-term. Short-term gains are taxed as ordinary income. For tax year 2025, IRS Topic 409 lists a 0% long-term rate for taxable income up to $48,350 (single) or $96,700 (married filing jointly), 15% for most people above that, and 20% at higher incomes. Net capital losses can offset up to $3,000 of other income a year ($1,500 if married filing separately), with the rest carried forward. The tax field here is a flat estimate — enter the rate that applies to you.
This calculator covers the price change only. Dividends received while you held the shares are taxed separately in the year paid (IRS Topic 404); add them to the sale proceeds to see the total return, or use the IRR calculator for a return that accounts for timing. Many brokers now charge no commission on online stock trades; set the fee fields to zero if so. Stocks aren't FDIC insured and can lose value.
Profit = (shares × sell price − sell fees) − (shares × buy price + buy fees). 100 shares bought at $50 and sold at $65 with $5 commissions each way: $1,490 profit.
Divide the profit by the cost basis (what you paid including fees). $1,490 ÷ $5,005 = 29.77%.
(Cost basis + sell commission) ÷ shares. For 100 shares bought at $50 with $5 to buy and $5 to sell, $50.10.
As capital gains when you sell. Held more than one year the gain is long-term and taxed at 0%, 15% or 20% depending on taxable income; held one year or less it is short-term and taxed as ordinary income (IRS Topic 409).
Capital losses first offset capital gains; IRS Topic 409 lets up to $3,000 of net capital loss ($1,500 if married filing separately) offset other income each year, with the rest carried forward.
Tax rules, limits and pay data change. Check the current figures with the primary source before acting on them.