When you calculate your net profit or loss on an investment, you have to factor in what it cost you to make the investment in the first place. That’s called the “cost basis” or “tax basis.”
Here’s a simple example: let’s say you buy 100 shares of Company A for $10 a share – $1,000 in total. That $1,000 is your cost basis. Your gain on the investment is whatever you make that’s above that number. So if you later sell those 100 shares for $15 a share, you make $1,500 in that transaction, but you have to subtract your cost basis, so your profit is $500. If you sell them for $7.50 a share, you make $750, but once you factor in your cost basis, you actually have a $250 loss.