Tested tool guide
Tested browser tools
Checked August 16, 2026
What Stock Profit/Loss Calculator does, with a checked example
A stock's price move is not its profit. Buy 100 shares at $50 and sell at $60 and the price math says $1,000, but commissions trim that and tax takes a cut that depends on how long you held. This calculator runs the whole chain: gross gain or loss from buy and sell prices, the net figure after commissions on both sides, percentage return on what you actually put in, and a short-term versus long-term capital gains tax estimate. The surprise is the holding period: cross the one-year line and the same gain is taxed at a much lower rate.
Worked example
A concrete input and expected output from the current implementation.
Input
Buy price $50.00, sell price $60.00, quantity 100, buy commission $5.00, sell commission $5.00, holding period 8 months (short-term), tax rate 22%
->
Expected output
Gross profit $1,000.00. Net profit after commissions $990.00 (19.78% return on the $5,005.00 total cost). Estimated capital gains tax at 22%: $217.80. After-tax profit: $772.20.
100 shares x ($60.00 - $50.00) = $1,000.00 gross. Total cost is $5,005.00 (shares plus buy commission) and proceeds are $5,995.00 (sales proceeds minus sell commission), so net profit is $990.00. Tax is 22% of the net gain because the 8-month hold makes the gain short-term.