Skip to content
Omnikalc

Stock profit calculator: gain, return and tax on a trade

Calculate the profit or loss on a stock trade after commissions and taxes, the percentage return and your break-even selling price.

Updated on
Your inputs

Value out of range

$

Value out of range

$

Value out of range

$

Value out of range

$

Value out of range

%

Value out of range

Results

Profit before tax

$1,500.00

Gain

Return on investment

30.00%

Profit after tax

$1,275.00

Estimated tax
$225.00
Break-even selling price per share
$50.00
Total cost of the purchase
$5,000.00
Net proceeds of the sale
$6,500.00

Profit, return and tax on a trade

When you sell shares, three numbers matter: the profit in dollars, the return in percent, and what is left after tax. Commissions are often zero at US brokers today, but they still matter for some accounts, foreign shares and options, and they shift your break-even price.

The formulas

  • Total cost = shares × purchase price + purchase commission
  • Profit = shares × selling price − sale commission − total cost
  • Return = profit ÷ total cost
  • Tax = profit × tax rate (zero on a loss)
  • Break-even price = (total cost + sale commission) ÷ shares

Worked example

You bought 100 shares at $50 and sell them at $65, with no commissions, and the gain is taxed at the 15% long-term rate.

  1. Total cost = 100 × 50 = $5,000.
  2. Profit = 100 × 65 − 5,000 = $1,500.
  3. Return = 1,500 ÷ 5,000 = 30%.
  4. Tax = 1,500 × 15% = $225, leaving $1,275 after tax.
  5. Break-even selling price = $50.00 a share.

US capital gains tax rates

Holding period Federal rate
One year or less (short-term) Ordinary income rates, 10% to 37%
More than one year (long-term) 0%, 15% or 20% depending on taxable income
High incomes, either period Plus 3.8% net investment income tax

Most states tax capital gains as ordinary income as well, while a few, such as Florida and Texas, have no income tax. Gains inside a 401(k), IRA or Roth IRA are not taxed when you sell.

Losses

If the result is negative, you have a capital loss. Losses first offset gains of the same year; up to $3,000 of net loss a year can then reduce ordinary income, and the rest carries forward. Beware of the wash sale rule: buying the same or a substantially identical security within 30 days before or after the sale disallows the loss for now.

What the return does not show

A 30% gain earned in one year is very different from the same gain over ten years, which is only about 2.7% a year. To compare trades held for different periods, use the compound annual growth rate. Dividends received while you held the shares are not included here either and add to your total return.

This calculator gives estimates for education and planning. It is not investment, tax or legal advice; for decisions about your own situation, talk to a qualified financial professional.

Frequently asked questions

How do you calculate profit on a stock?

Profit = shares × selling price − sale commission − (shares × purchase price + purchase commission). 100 shares bought at $50 and sold at $65 give a $1,500 profit without fees.

How do you calculate the return in percent?

Divide the profit by the total cost of the purchase: $1,500 ÷ $5,000 = 30%. This return does not account for how long you held the shares.

How are stock profits taxed in the US?

Shares held more than a year are taxed at long-term rates of 0%, 15% or 20% depending on income, plus 3.8% net investment income tax at high incomes. Shares held a year or less are taxed as ordinary income.

What is the break-even price?

The selling price at which you neither gain nor lose after commissions: (shares × purchase price + both commissions) ÷ shares.

Was this calculator helpful?

Thanks for your feedback!

Results are estimates provided for information purposes. They do not replace professional advice.