When you sell shares of stock you’ve invested in, you naturally want to know how much money you made. In addition, you need to calculate stock profit because the IRS will also want to know. However, how you calculate stock profit depends in part on what your purpose is. You’ll use one method to figure your gross profit ad another to find the capital gain that is subject to income taxes. It’s important to keep careful records of each stock transaction so that you can make accurate calculations.

### Things You'll Need

- Stock transaction records

- Calculator

Determine the amount of money you invested. Add all purchase and transaction fees to the amount originally paid for the stock. If you paid $2,500 and had $100 in transaction fees, this gives you a total investment of $2,600.

Figure your gross stock profit. First, add any dividends taken in cash to the amount you received from the sale of the stock. Then subtract your total investment. For example, suppose you sold the stock in Step 1 for $3,000 and also had $200 in dividends taken in cash rater than being reinvested, giving you a total amount received of $3,200. Subtracting the total investment of $2,600 leaves a gross profit of $600.

Find the cost basis (also called tax basis) for figuring profit subject to capital gains taxes. To do this, add any reinvested dividends (but not dividends taken in cash) to your total investment in Step 1. If the total investment was $2,600 and you reinvested $200 in dividends, your tax basis works out to $2,800.

Convert gross stock profit to a percentage by dividing the dollar amount of gross profit by the total investment and multiply by 100. In the above example, you would divide $600 by $2,600 to get 0.231. Multiplied by 100 you get 23.1 percent stock profit.

Calculate capital gains by subtracting the tax basis from the amount received from the sale of the stock. If you sold the stock for $3,000 and the tax basis is $2,800, the stock profit subject to capital gains tax is $200.