Invest · Trade · Crypto

Average Cost / Cost Basis Calculator

Combine purchase lots to estimate total cost basis and average cost per unit.

Your scenario

$
$
$

Currency convention: dollar symbols are display shorthand. Enter all money amounts in the same currency; no foreign-exchange conversion is performed.

Your result

Average cost per unit
Total cost basis
Total quantity

Through the Lens

What drives this result?

Controlled, deterministic sensitivity around your current inputs reveals which assumptions move the average cost per unit most.

No AI in the ranking
Purchase 2 priceHigh modeled impact

Higher input raises the modeled result

Each lot price is weighted by its quantity.

Purchase 1 priceLow modeled impact

Higher input raises the modeled result

Each lot price is weighted by its quantity.

Purchase 2 quantityLow modeled impact

Higher input raises the modeled result

Quantity changes how much influence the second lot has.

Purchase 1 quantityLow modeled impact

Higher input lowers the modeled result

Quantity changes how much influence the first lot has.

Entered feesLow modeled impact

Higher input raises the modeled result

Fees add to total cost before division by total units.

High modeled impact means an input changes this output substantially around the current scenario. Rankings compare controlled 10% input changes; they do not measure risk, probability, personal importance, controllability, suitability, advice, or forecasts.

Read the sensitivity methodology
Meaning

What this means

Meaning

Average cost is total cost basis divided by total units. It gives a useful break-even reference before taxes or future selling costs.

Implication

The weighted average gives a unit-level cost reference. It is not necessarily the tax basis recognized by a tax authority when account adjustments or lot-selection rules apply.

Formula and methodology

How the calculator works

Lot cost
quantity × purchase price + entered fees
Total cost basis
sum of all lot costs
Average cost per unit
total cost basis ÷ total quantity

The two entered purchase lots are combined. The single fee input is included once in total cost. Money is displayed to two decimals for average cost and whole currency units for total cost.

Assumptions and limitations

What the scenario includes—and leaves out

Assumptions

  • Both purchases are of the same asset and use the same currency.
  • Entered fees are acquisition costs that should be included in the scenario basis.
  • Quantities and prices have already been adjusted for any splits or reorganizations.

Limitations

  • Selling costs, taxes, foreign exchange, distributions, corporate actions, and jurisdiction-specific basis adjustments are excluded.
  • The result does not select tax lots or establish an official tax basis.
  • No broker or exchange data is fetched.

Educational scenario only. Results are modeled estimates, not forecasts or personalized financial, investment, legal, or tax advice.

Known-answer checks

Examples used to validate the engine

Weighted average10 units at 20 and 30 units at 40 produce a total cost of 1,400 and average cost of 35.
Fees includedA 20 fee raises the same example’s total cost to 1,420 and average to 35.50.
Decimal unitsPositive fractional quantities are accepted.
Invalid lotZero quantity, negative price or fees, and non-finite values are rejected.
Look deeper

Continue the analysis