Average Cost Calculator for Stocks: Cost Basis, Realized & Unrealized Gain

Average Cost / Cost Basis Calculator

Bought the same stock more than once? Enter each buy, plus a sale if you made one, to see your average cost, the gain you locked in and the gain still on paper.

  • Uses the average cost method. Brokers often default to FIFO or specific lots for stocks, which can give a different realized gain, so check your broker's cost basis setting.
  • Fees can be added to the price per share if you want them in your basis.