Cost Basis Calculator Stocks

Calculating the cost basis for stocks is essential for investors, as it helps determine the capital gain or loss on their investments. This Cost Basis Calculator simplifies the process, allowing you to quickly and accurately compute the cost basis for your stock transactions.


The cost basis is calculated by multiplying the purchase price per share by the number of shares owned:

Cost Basis = Purchase Price per Share × Shares Owned

The capital gain is then determined by subtracting the cost basis from the proceeds of the sale:

Capital Gain = Sale Price per Share × Shares Owned – Cost Basis

How to Use:

  1. Enter the purchase price per share in the “Purchase Price” field.
  2. Input the number of shares owned in the “Shares Owned” field.
  3. Specify the sale price per share in the “Sale Price” field.
  4. Click the “Calculate” button to see the results.


Suppose you purchased 100 shares of a stock at $50 per share and later sold them at $60 per share.

  • Purchase Price: $50
  • Shares Owned: 100
  • Sale Price: $60

Upon clicking “Calculate,” you will get the following result:

  • Cost Basis: $5,000.00
  • Proceeds: $6,000.00
  • Capital Gain: $1,000.00

This indicates a capital gain of $1,000.00 on your stock investment.


  1. What is a cost basis for stocks?
    • The cost basis is the original value of an asset, such as stocks, for tax purposes.
  2. Why is it important to calculate the cost basis?
    • Calculating the cost basis helps determine the capital gain or loss when selling stocks, which is crucial for tax reporting.
  3. What if I bought shares at different prices?
    • You need to calculate the cost basis for each purchase separately and then sum them up to get the total cost basis.
  4. Can I use this calculator for other investments besides stocks?
    • While primarily designed for stocks, you can use this calculator for other assets with a similar cost basis calculation method.
  5. Is the result displayed here suitable for tax reporting?
    • This calculator provides an estimate. For accurate tax reporting, consult a tax professional.


The Cost Basis Calculator for stocks simplifies the process of determining your cost basis and capital gain. Whether you are a novice investor or a seasoned trader, having an accurate cost basis is essential for making informed financial decisions and complying with tax regulations. Use this calculator to streamline the process and gain a better understanding of your investments.

Leave a Comment