Figuring out whether you made a profit on a stock investment is easy: if you sold the shares for more than you paid, it’s a safe bet you made at least a little profit. But when it comes time to do your taxes, it gets a little more complicated. You start calculating what you owe Uncle Sam by determining the cost basis of stocks. Cost basis is the total cost of the investment, and includes expenses you incurred besides the price paid for the shares, such as transaction fees. This works to your advantage because cost basis is always more than the cost of the shares themselves, reducing your capital gains and thus the amount of taxable profit.

Multiply the price you paid per share by the number of shares of stock you purchased to find the total purchase price. If you bought some shares at different times, calculate each purchase transaction separately and then add the total purchase prices together. You may not need to actually do these computations, since many brokers do it for you and list the information on your account statement.

Exclude any dividends you received while you owned the stock. Dividends are considered earnings and are taxed as ordinary income, not as capital gains.

Make certain you calculate cost basis for the correct shares if you sold only some of your holdings of a particular stock. Unless you instruct your broker to sell specific shares, the IRS assumes the first shares bought are the first ones you sold.

Add all fees, broker commissions and other transaction costs for the purchase and sale of the stock to the total purchase price. The result is the cost basis for the stock.

### Items you will need

- Stock trading records

#### Tip

- Once you’ve determined cost basis for a stock investment, subtract it from the total proceeds from the sale of the stock. The result is your capital gain or loss on the investment. If you made money, it will subject to income taxes unless you have offsetting capital losses.