Capital gains
The profit when you sell an investment for more than you paid. It is taxed when you sell, in a regular brokerage account.
If you held the investment 1 year or less, the gain is short-term and taxed like your paycheck. If you held it more than 1 year, it is long-term and taxed at 0%, 15% or 20%, depending on your income.
Gains inside a 401(k) or IRA are not taxed when they happen. If you sell at a loss in a taxable account, the loss can offset gains and lower your tax.
Example
Buy shares for $2,000 and sell them for $3,000, and your capital gain is $3,000 − $2,000 = $1,000.