When you bought a cryptocurrency in several purchases at different prices, then sell part of it, which purchase price should you use to calculate the gain? There are several conventions. The most common are the weighted average cost and FIFO (first in, first out). For tax, France applies a third method specific to crypto-assets: a whole-portfolio formula. This guide compares all three on one example.

Related tools: the DCA calculator gives your weighted average cost; the French crypto tax calculator applies the French form 2086 method.

1. The example

You buy 1 BTC for €20,000, then 1 BTC for €40,000. Later, bitcoin is worth €50,000 and you sell 0.5 BTC, i.e. €25,000 (fees ignored for simplicity).

2. Weighted average cost

All purchases are pooled: the cost of one unit is the total cost divided by the total quantity.

Average cost = €60,000 ÷ 2 BTC = €30,000; gain = 25,000 − 0.5 × 30,000 = €10,000

The average cost does not change after a sale: the remaining 1.5 BTC keep a cost of €30,000 per unit. It is the simplest way to track an asset’s performance, and the one shown by the DCA calculator.

3. FIFO (first in, first out)

The units sold are assumed to be the oldest ones. The 0.5 BTC sold come from the first purchase, at €20,000 per unit.

FIFO gain = 25,000 − 0.5 × 20,000 = €15,000

You are left with 0.5 BTC at €20,000 and 1 BTC at €40,000. FIFO requires tracking each lot. It gives a higher gain when prices have risen, since the first units were cheaper. The opposite method, LIFO (last in, first out), would give 25,000 − 0.5 × 40,000 = €5,000 here.

4. The French method (article 150 VH bis)

For individuals tax-resident in France, neither method applies. The gain is calculated on the whole crypto-asset portfolio:

Gain = sale price − total acquisition price × sale price ÷ total portfolio value

If the portfolio only holds these 2 BTC, worth €100,000 at the time of the sale: 25,000 − 60,000 × 25,000 ÷ 100,000 = €10,000. With a single asset and no earlier sale, you get the average-cost result.

But the formula takes all your crypto-assets into account. Suppose you also hold ether bought for €10,000 and now worth €30,000. The total acquisition price becomes €70,000 and the total value €130,000:

25,000 − 70,000 × 25,000 ÷ 130,000 ≈ 25,000 − 13,461.54 = €11,538.46

So the taxable gain on the bitcoin sale also depends on your other cryptos. The €13,461.54 deducted is the “initial capital fraction”, which will reduce the total acquisition price for later sales. The guide on French crypto capital gains and form 2086 explains this method in detail.

5. Summary

MethodGain on the 0.5 BTC saleUse
Weighted average cost€10,000Tracking an asset’s performance
FIFO€15,000Lot-by-lot tracking (oldest units sold first)
LIFO€5,000Lot-by-lot tracking (newest units sold first)
French method (BTC only)€10,000Individual tax in France (form 2086)
French method (BTC + ETH)€11,538.46

To track an investment’s return, the average cost is enough. To declare gains in France, use the whole-portfolio formula. Elsewhere, the method depends on local tax rules: check with the relevant tax authority.

This guide compares calculation methods for information only. It is neither tax advice nor investment advice.