Personal Finance Insurance Credit Score Credit Cards Loans Investing Calculators All guides Subscribe

Stock Profit Calculator

This stock profit calculator works out the dollar gain or loss on a trade, your percentage and annualized return, the break-even sell price and an after-tax profit estimate. It is designed for individual investors checking a closed trade or planning an exit.

What is stock profit?

Stock profit is what you keep after selling shares: the sale proceeds minus what you paid, minus trading fees, plus any dividends you collected while you held the position. A trade can look profitable on price alone yet shrink once fees and taxes are counted, which is why it helps to see the full picture.

The percentage return shows how hard your money worked, but it ignores time. A 30% gain over one year is very different from 30% over five years, so the calculator also converts your result into an annualized return that you can compare with other investments.

How to use the Stock Profit Calculator

  1. Shares — the number of shares you bought and sold.
  2. Buy price per share and Sell price per share — from your brokerage trade confirmations. Enter a target price instead if you are planning a sale.
  3. Total fees — commissions and any other trading costs for both the buy and the sell. Many brokers charge $0 commissions on US stocks.
  4. Dividends received — cash dividends paid while you held the shares. Your brokerage’s annual 1099-DIV lists them.
  5. Days held — the number of days between the purchase and the sale.
  6. Tax rate on the gain — use 0%, 15% or 20% for long-term gains, or your ordinary income tax rate if you held the shares for one year or less.

How stock profit is calculated

The calculator multiplies shares by the buy and sell prices to find your cost and proceeds, then adjusts for fees and dividends.

Profit = (Shares × Sell price) − (Shares × Buy price) − Fees + DividendsReturn = Profit ÷ Cost. Annualized return = (1 + Return)365 ÷ Days held − 1. Break-even sell price = (Cost + Fees − Dividends) ÷ Shares.

After-tax profit applies your tax rate to a positive gain. The holding period label shows long-term if you held for more than 365 days and short-term otherwise, because the IRS taxes short-term gains as ordinary income. Note that the tax rate you enter is used either way, so set it to match the holding period.

Worked example

You bought 100 shares at $50 and sold them at $65 after 400 days, with no fees or dividends. Because you held for more than a year, the gain is long-term, and you fall in the 15% capital gains bracket.

Item Value
Cost (100 × $50) $5,000
Proceeds (100 × $65) $6,500
Return 30.00%
Annualized return (400 days) 27.05%
Tax at 15% $225.00
After-tax profit $1,275.00
Profit before tax $1,500.00

Had you sold the same shares after 200 days, the annualized return would jump to about 61%, but the gain would be short-term and taxed at your ordinary income rate rather than 15%.

Interpreting the results

  • Use annualized return to compare trades of different lengths. Be careful with very short holds: a small gain over a few days annualizes into an unrealistically large number.
  • Holding more than one year can cut the tax on a gain sharply. Check the date before selling a winner that is close to the one-year mark.
  • The break-even sell price tells you where you stop losing money once fees and dividends are counted, which is useful when setting a stop or a limit order.
  • Losses can offset gains. Selling a losing position in the same year can reduce the tax on your winners, subject to the wash-sale rule if you buy the same stock within 30 days before or after the sale.
  • If you bought in several lots at different prices, your broker’s cost basis records decide which shares were sold. Enter the average price or the specific lot.

Keep in mind: this is a simple estimate. It does not handle stock splits, multiple purchase lots, the 3.8% net investment income tax that applies above $200,000 of income for single filers ($250,000 married filing jointly), or state income tax.

Frequently asked questions

How do you calculate profit on a stock?

Multiply the number of shares by the sell price, subtract the number of shares times the buy price, subtract any fees and add dividends received. Divide the profit by your original cost to get the percentage return.

How much tax do I pay on stock profits?

Shares held for more than one year qualify for long-term capital gains rates of 0%, 15% or 20%, depending on your taxable income. Shares held one year or less are taxed at your ordinary income tax rate. Higher earners may also owe the 3.8% net investment income tax.

What is a good annual return on a stock?

There is no single answer, but a common yardstick is the return of a broad index fund over the same period. If a stock you picked did worse than the index after fees and taxes, a low-cost index fund would have served you better for that trade.

Do dividends count as profit?

Yes. Dividends are part of your total return, so the calculator adds them to the price gain. They are taxed separately in the year you receive them, at qualified dividend rates or as ordinary income depending on the type.

What is a break-even price in stocks?

It is the sell price at which you neither make nor lose money after fees and dividends. It equals your total cost plus fees, minus dividends received, divided by the number of shares.

Results are estimates for educational purposes and are not financial, tax or legal advice. Figures reflect 2026 rules where noted; confirm details with official sources or a qualified professional.

Learn more

Guides that use this calculator

Scroll to Top