When you sell a stock at a loss and repurchase a substantially identical stock within 30 days, your transaction will likely be considered as a wash sale. A taxpayer cannot deduct losses incurred from wash sales, however, gains from such sales are taxable.
A wash sale results when a taxpayer sells stock or securities at a loss and within 30 days before or after the sale, buys, in a fully taxable trade, substantially identical stock or securities. This rule also applies if you sell the stock and your spouse, or a corporation you control, buys the substantially identical stock. Under the wash sale rules, the term “stock or securities” includes contracts or options to acquire or sell stocks or securities.