Finder makes money from featured partners, but editorial opinions are our own. Advertiser Disclosure

Not knowing your stock’s cost basis can cost you

Minimize capital gains tax by identifying the optimal cost basis method for your investments.

If you purchase stocks, the time may come when you’re ready to sell — and knowing what to sell matters. That’s where cost basis comes into play.

Cost basis defined

Cost basis is the amount you paid to purchase an investment, including any trading, commission or brokerage fees. There are several methods that can be used to calculate cost basis, including average cost, specific share identification and first-in, first-out (FIFO).

Cost basis:

The original purchase price of an investment for tax purposes.

The good news is you typically won’t need to run the numbers to determine your cost basis. Your broker has likely already done it for you. But you need to understand how cost basis impacts your investments — primarily because it affects your taxable income.

Why does cost basis matter to you?

For one: it’s an investor’s responsibility to report cost basis information to the IRS by submitting Form 8949. But don’t panic — brokers are required by law to report cost basis and capital gains on Form 1099-B, which they then distribute to investors.

Plus, cost basis can help you identify any capital gains earned from the sale of an investment. And knowing how much profit you’ve made from a sale is important, because capital gains are subject to tax. Cost basis can also help you identify potential losses; losses of up to $3,000 can be deducted from your taxable income annually.

Calculating cost basis doesn’t really come into play unless you’re selling investments from a taxable brokerage account. Why? Because investments in tax-advantaged accounts aren’t subject to the same capital gains taxes as investments in taxable accounts, like individual retirement accounts (IRAs) and 401(k)s.

How cost basis works

Cost basis can help you determine capital gains and losses as they pertain to taxable income. Simply put:

  • Gains and losses are the result of subtracting an investment’s cost basis from its sale price.
  • If the figure is a positive number, you’ve generated a capital gain.
  • If the figure is a negative number, you’ve generated a loss.

There are multiple ways to calculate cost basis because how and when you sell off your investments matters. Ultimately, you want to lessen the impact of capital gains. And the cost basis method you use has the potential to impact how much in taxes you’ll pay come tax season.

4 ways to calculate cost basis

While you may not be responsible for crunching the numbers — your broker will do that for you — it will help for you to get a basic understanding of how cost basis can be calculated. It will also help you to identify which method your broker relies on to calculate cost basis.

Average cost; specific share identification; first-in, first-out; and last-in, first-out are four of the most popular methods of calculating cost basis. But additional methods also exist. More than likely, your broker will use the average cost basis method.

MethodDescription
Average cost methodThe total amount invested is divided by the number of shares owned.
Specific share identification methodYou hand-pick which shares are sold in order to minimize tax impact.
First-in, first-out (FIFO) methodWhen selling numerous investments of the same type, the first assets bought will be the first to be sold.
Last-in, first-out (LIFO) methodWhen selling numerous investments of the same type, the last assets bought will be the first to be sold.

Calculating cost basis

Cost basis varies by method. And the best way to understand the different methods is to see them in action.

Let’s say you bought a number of shares from Company X over the course of four years.

  • Year one: You purchased 50 shares at $10 per share.
  • Year two: You purchased 25 shares at $12 per share.
  • Year three: You purchased 25 shares at $15 per share.
  • Year four: You purchased 50 shares at $16 per share.

Your total investment over four years? $1,975 for 150 shares.

A few months later, you decide you’d like to sell 25 shares at the current market price of $17, resulting in a profit of $425. Let’s see how the cost basis for this sale shakes out by method.

Average cost

Average cost takes the total cost of your combined shares — $1,975 — and divides it by the total number of shares purchased –– 150. This brings your cost basis to $13.16 per share. To arrive at the cost basis of your sale, multiply the cost basis per share by the number shares sold. This works out to a cost basis of $329.

After selling 25 shares for $425, you realize a capital gain of $96 for the sale using the average cost method.

Specific share identification

Using this method, you select which shares you’d prefer to sell. Ideally, you want to arrive at the highest figure possible when calculating cost basis to reduce taxable capital gains. The easiest way to do this is by selling shares you purchased for a higher price — in this case, the shares you bought in year four for $16 per share.

That said, selling shares you’ve held for less than one year will result in being taxed at short-term capital gains rates, which treats capital gains like ordinary income and can result in higher tax rates.

First-in, first-out (FIFO)

The first-in, first-out method dictates that the shares you bought first will be the first sold. Since your first batch of 50 shares was purchased for $10 per share, your sale of 25 shares will result in a cost basis of $250.

After selling 25 shares for $425, you realize a capital gain of $175 for the sale using the first-in, first-out method.

Last-in, first-out (LIFO)

The last-in, last-out method dictates that the shares you bought last will be the first sold. Since your final batch of 50 shares was purchased for $16 per share, your sale of 25 shares will result in a cost basis of $400. Keep in mind that you’ll be taxed at short-term capital gains rates because you’re selling shares that were purchased less than one year ago.

After selling 25 shares for $425, you realize a capital gain of $25 for the sale using the last-in, first-out method.

Adjusted cost basis: 7 factors that affect cost basis

If cost basis was nothing more than the price you paid for an investment, things would be a whole lot simpler. But that isn’t the case. When determining cost basis, you need to adjust your calculations based on a handful of additional factors — and these factors differ depending on the type of investment you’re selling.

1. Dividends

The biggest factor you need to consider when calculating the adjusted cost basis of a stock is dividends. If you purchased 10 shares for $100, received a dividend of $6 and reinvested the dividend, your adjusted cost basis would be $106 — not the $100 you paid for the initial investment.

2. Bond interest

Now, bonds don’t pay dividends, but they do pay interest. But you don’t need to factor interest into your adjusted cost basis for bonds because bond interest is taxed as ordinary income — not a capital gain.

3. Stock splits

Stock splits will affect your cost basis, but the overall value of your investment will remain unchanged. So, let’s say you purchased 10 shares for $100 and the company issued a 2:1 stock split. Now your 10 shares have become 20 shares and your per share cost basis dropped from $10 per share to $5 per share.

4. Mergers and acquisitions

Mergers may also affect your cost basis — but not always. If a merger results in a difference in the number of shares you hold, this will affect your cost basis in much the same way as a stock split. More shares will result in a smaller cost basis. But for most mergers, the cost basis of the stock after the acquisition will be factored into the restructuring of the stock.

5. Real estate

Finding the adjusted cost basis for real estate investments can get complicated in a hurry — and that’s because there are numerous factors that affect the value of real estate after it’s been purchased, including:

  • Home improvements and renovations.
  • Depreciation.
  • Insurance payouts.
  • Zoning costs.
  • Residential energy credits.

You may have paid $100,000 to acquire a rental property, but if you spent $10,000 to redo the roof, you’ve increased the value of the property and this needs to be factored into the adjusted cost basis.

6. Inherited or gifted investments

Inheriting investments can also complicate the adjusted cost basis. When valuing an investment that’s been inherited, your cost basis is based on the fair market value of the asset on the date of the individual’s death — not what that person originally paid.

Oh, and if you’re given an investment as a gift by someone who is still alive, the rules — again — diverge:

  • Stock’s fair market value is equal to or greater than the giver’s cost basis: The cost basis is based on the giver’s cost basis.
  • Stock’s fair market value is less than the giver’s basis: The cost basis is based on fair market value on the date the investment was gifted.

7. Short- and long-term capital gains

Short- and long-term capital gains come into effect when relying on the specific share identification method of calculating cost basis. Essentially, you need to take into account the amount of time you’ve held an investment when picking which investments to sell off.

Is it worth selling shares you’ve held for less than a year and getting taxed at the potentially higher short-term rate? Possibly.

How much did you pay for those shares? Will selling them result in higher capital gains? Bigger capital losses? These must all be factored into your decision before you sell.

Compare stock trading platforms

Name Product Asset types Option trade fee Annual fee Signup bonus
M1 Finance
Stocks
$0
0%
Free 1-year trial of M1 Plus
when you sign up for M1 Finance
Invest in your favorite stocks or in curated portfolios with automatic rebalancing.
SoFi Invest
Stocks, ETFs, Cryptocurrency
N/A
0%
Get one free stock worth up to $1,000
Open an account
A free way to invest in most equities.
TradeStation
Stocks, Bonds, Options, Mutual funds, ETFs, Cryptocurrency
$0 + $0.50/contract
$0 per month
$10 of crypto
Open an account with access to crypto
A platform built for all kinds of traders and all styles of trading
Robinhood
Stocks, Options, ETFs, Cryptocurrency
$0
0%
Free stock (chosen randomly with a value anywhere between $2.50 and $200)
Sign up using the "go to site" link
Make unlimited commission-free trades in stocks, funds, and options with Robinhood Financial.
Stash Invest
Stocks, ETFs
$0
$1 per month
$5
Add at least $5 to your Invest account
Stash is more than an investment app. You’ll have access to tools that can help you become a confident investor.
Public
Stocks, ETFs, Cryptocurrency
N/A
$0 per month
Download and sign up with Public.com; approved accounts receive a free stock slice worth up to $300, selected from 9 popular stocks.
Open an account
Commission-free trading in stocks and ETFs with a social networking twist.
loading

Compare up to 4 providers

*Signup bonus information updated weekly.

Bottom line: Cost basis affects taxes owed

Knowing how to calculate cost basis and what factors you need to adjust for is important because the cost basis of your investments impacts the amount of tax you owe. True tax-free investments don’t exist, but knowing how to minimize taxes owed on your investments can help.

More guides on Finder

Ask an Expert

You are about to post a question on finder.com:

  • Do not enter personal information (eg. surname, phone number, bank details) as your question will be made public
  • finder.com is a financial comparison and information service, not a bank or product provider
  • We cannot provide you with personal advice or recommendations
  • Your answer might already be waiting – check previous questions below to see if yours has already been asked

Finder.com provides guides and information on a range of products and services. Because our content is not financial advice, we suggest talking with a professional before you make any decision.

By submitting your comment or question, you agree to our Privacy and Cookies Policy and finder.com Terms of Use.

Questions and responses on finder.com are not provided, paid for or otherwise endorsed by any bank or brand. These banks and brands are not responsible for ensuring that comments are answered or accurate.
Go to site