FIFO Calculation
How capital gains are calculated under German tax law
When you sell stocks or ETFs, the tax office needs to know: which exact shares did you sell? The answer comes from the FIFO method (First In, First Out) – it is legally required under § 20 Abs. 4 Satz 7 EStG.
How FIFO Works
The FIFO method assumes that the first securities purchased are also sold first. This determines the acquisition costs and thus the taxable gain or loss.
Example
- 📥 Buy: 100 shares at €50 each on 01.01.2024
- 📥 Buy: 100 shares at €70 each on 01.06.2024
- 📤 Sell: 100 shares at €80 each on 01.12.2024
Result: The first purchased shares (€50) are considered sold → Gain: 100 × (€80 - €50) = €3,000
Why FIFO Matters
- FIFO is legally required – other methods are not accepted by the tax authorities
- IBKR uses different calculation methods by default – broker reports are therefore not accurate for German tax returns
- BubbleTax automatically applies FIFO to all your transactions – no manual recalculation needed