Selling an investment typically has tax consequences. To figure out whether you need to report a gain -- or can claim a loss -- after you sell, you need to know the cost basis for that investment.

For stocks or bonds, the cost basis is generally the price you paid to purchase the securities, including purchases made by reinvestment of dividends or capital gains distributions, plus other costs such as the commission or other fees you may have paid to complete the transaction. You usually get this information on the confirmation statement that the broker sends you after you have purchased a security.

You -- the taxpayer -- are responsible for reporting your cost-basis information accurately to the IRS. You do this, in most cases, by filling out Form 8949. (For tax history junkies, this form replaced the Form 1040 Schedule D-1 in taxable year 2011 for most cost-basis reporting.)

Image source: Getty Images.

You're not totally on your own when it comes to computing cost basis. In 2008, Congress passed a law that requires brokerage firms, mutual funds, and others to give you a hand.

Brokerage-firm responsibilities

In its Cost Basis Reporting FAQs, the IRS lays out what cost-basis reporting must be provided by brokerage firms and other financial institutions. Currently, brokerage firms must report cost basis and the type of capital gain (short-term or long-term) on Form 1099-B, or a substitute statement, for the sale of the following types of securities:

  • Shares of stock, including exchange-traded funds (ETFs), that are not treated as regulated investment companies (RICs) for taxation purposes, that you acquired on or after January 1, 2011.
  • Shares of stock in RICs and stocks acquired in connection with dividend reinvestment plans acquired on or after January 1, 2012.
  • Specific debt securities (for example bonds with a fixed rate of interest and fixed maturity date), securities futures contracts, options, rights and warrants purchased or acquired on or after January 1, 2014.
  • All other debt securities -- for example, zero-coupon bonds that convert into interest-paying bonds -- purchased or acquired on or after January 1, 2016. (This tax information will be reportable on 1099-B forms filed in 2017.)

Investors should receive a copy of any 1099-B or substitute statement from their brokerage firms by Feb.15. Review this information as soon as you get it. Check that the amount of cost basis your broker reports to the IRS matches your own records -- and if the amounts differ, contact the broker immediately to discuss any differences you find.

Investors should be aware that there are situations in which a firm may not be required -- or is simply unable -- to provide a cost basis for a sale. This could be the case if the securities you sold were purchased many years ago, or if you transferred your holdings from one securities firm to another prior to the new reporting requirements.

If you have questions about what sales are reportable by your brokerage firm, you shouldn't hesitate to contact your financial professional. Many firms also have a section on their websites explaining cost basis, and the specific cost-basis information they provide to their customers.

Four record-keeping tips

While brokerages have cost-basis reporting obligations, it's still important to keep good records of your transactions. Follow these tips:

  1. Hold on to trade confirmations showing how much you paid for specific shares, or keep track of that information on your own records at home.
  2. Keep track of stock dividends or non-dividend distributions you receive because they may affect the cost basis of your shares.
  3. If you purchased stock of a company at different times and prices, and can adequately identify the shares you sold, their basis is the cost for those specific shares (the IRS calls this "specific share identification"). If you cannot determine exactly which shares you're selling, tax rules generally require you to calculate a gain or loss as if you're selling the earliest acquired shares -- sometimes referred to as the "first in, first out" method.
  4. If you received the securities as a gift or through an inheritance, you may have to find the fair-market value when it was given to you, or the previous owner's adjusted basis.

IRS Publication 550 offers detailed guidance on how to calculate cost basis under different circumstances. It's also a sound practice to consult with a tax professional when computing and reporting a gain or loss.

The bottom line is that the IRS expects you to keep and maintain records that identify the cost basis of your securities. If you don't have adequate records, you may have to rely on the cost basis that your broker reports -- or you may be required to treat the cost basis as zero. For this reason, you may want to check whether you have cost-basis information for any securities you want to sell before you do so.

Subscribe to FINRA's Investor News newsletter for more information about saving and investing.