Bitcoin Cost Basis Methods: FIFO vs LIFO vs HIFO vs Specific ID
Compare Bitcoin tax cost basis methods (FIFO, LIFO, HIFO, Specific Identification) and their impact on capital gains. Includes worked examples and IRS rules.
Cost Basis Methods Overview
When you sell Bitcoin, the IRS taxes the difference between your sale price and the original purchase price of the specific coins you sold. That original purchase price is your cost basis. If you bought Bitcoin at multiple prices over time (which most holders have), the method you use to determine which coins were "sold" directly controls how much tax you owe.
The IRS recognizes two formal methods for determining cost basis: FIFO (First In, First Out) as the default, and Specific Identification as the alternative. LIFO (Last In, First Out) and HIFO (Highest In, First Out) are not standalone IRS methods: they are lot-selection strategies executed within the Specific Identification framework. Each produces materially different tax outcomes for the same transactions.
| Method | Selection Rule | IRS Classification | Documentation Required | Best For |
|---|---|---|---|---|
| FIFO | Sell oldest lots first | Default method | Minimal | Simplicity, long-term capital gains |
| LIFO | Sell newest lots first | Specific Identification | Contemporaneous records | Reducing gains in rising markets |
| HIFO | Sell highest-cost lots first | Specific Identification | Contemporaneous records | Minimizing recognized gains |
| Specific ID | Taxpayer selects per transaction | Specific Identification | Per-transaction lot designation | Maximum flexibility |
Worked Example: Same Sale, Four Different Tax Outcomes
Consider a taxpayer who acquired Bitcoin in three separate purchases, then sells 1 BTC on August 20, 2025 for $50,000:
| Lot | Purchase Date | Cost Basis | Holding Period |
|---|---|---|---|
| Lot 1 | January 10, 2023 | $20,000 | Long-term (over 1 year) |
| Lot 2 | June 15, 2023 | $40,000 | Long-term (over 1 year) |
| Lot 3 | March 1, 2025 | $30,000 | Short-term (under 1 year) |
Sale: 1 BTC at $50,000. Here is how each method changes the result:
| Method | Lot Sold | Capital Gain | Gain Type | Effective Tax Rate Range |
|---|---|---|---|---|
| FIFO | Lot 1 ($20,000) | $30,000 | Long-term | 0% / 15% / 20% |
| LIFO | Lot 3 ($30,000) | $20,000 | Short-term | 10% to 37% |
| HIFO | Lot 2 ($40,000) | $10,000 | Long-term | 0% / 15% / 20% |
| Specific ID | Taxpayer chooses | Varies | Varies | Depends on lot selected |
HIFO produces the lowest recognized gain ($10,000) at favorable long-term rates. FIFO produces the largest gain ($30,000) but also qualifies for long-term rates. LIFO yields a $20,000 gain but at short-term ordinary income rates, which can reach 37% at the federal level. For a taxpayer in the 24% bracket, HIFO saves roughly $3,000 to $4,500 in taxes compared to FIFO on this single transaction.
Note: The optimal method depends on your full tax picture. A $10,000 long-term gain taxed at 15% ($1,500) beats a $20,000 short-term gain taxed at 24% ($4,800). Both the size of the gain and the holding period matter.
How Each Method Works
FIFO: First In, First Out
FIFO sells your oldest Bitcoin first. It is the IRS default: if you do not make a valid specific identification, the IRS assumes FIFO. Under the 2024 final regulations (TD 9989), brokers reporting on Form 1099-DA apply FIFO by default on a per-wallet basis starting in the 2025 tax year.
FIFO tends to produce long-term capital gains because it sells the lots you have held the longest. In a rising market, however, it also produces the largest gains because your oldest purchases typically have the lowest cost basis. FIFO is straightforward and requires no special documentation beyond standard transaction records.
LIFO: Last In, First Out
LIFO sells your most recently purchased Bitcoin first. Because recent purchases in a rising market tend to have higher cost bases, LIFO generally reduces the size of your recognized gain. The tradeoff: those recent lots are often held less than one year, making the gain short-term and subject to ordinary income tax rates (up to 37% federally).
LIFO is most useful in a falling market where you have recently purchased Bitcoin at prices above your sale price, allowing you to realize losses. Under IRS rules, LIFO requires valid specific identification documentation.
HIFO: Highest In, First Out
HIFO sells the lots with the highest cost basis first, regardless of when they were acquired. This minimizes the recognized gain (or maximizes the recognized loss) on every sale, making it the most tax-efficient method for most taxpayers in most market conditions.
Like LIFO, HIFO is implemented through specific identification. You must have a standing instruction documented before each disposal that specifies your lots should be relieved in highest-cost-first order. Many crypto tax software platforms support HIFO as a selectable option, but selecting it in software alone does not satisfy the IRS documentation requirement.
Specific Identification
Specific Identification gives you full control: you designate exactly which lot is being sold on each transaction. This allows per-transaction optimization: you might sell a high-cost lot in January to minimize gains, then sell a low-cost long-term lot in December to harvest a favorable rate.
The IRS requires "adequate identification" under Treasury Regulation section 1.1012-1(c). This means contemporaneous records showing: the date and time of acquisition, cost basis, wallet or account identifier, quantity disposed, explicit mapping to acquisition lots, and a standing instruction or per-transaction designation recorded before the disposal occurs. Retroactive lot selection is not permitted.
Bull Market vs Bear Market Tax Strategies
The optimal cost basis method shifts with market conditions. Here is how each method performs across scenarios:
In a bull market (selling above all purchase prices):
- HIFO minimizes gains by selling the highest-cost lots first
- FIFO produces larger gains but at long-term rates if held over 12 months
- LIFO may produce smaller gains but often at short-term rates
- Specific ID allows cherry-picking lots for optimal rate and gain combinations
In a bear market (selling below some purchase prices):
- HIFO and LIFO let you realize losses by selling lots purchased at higher prices
- FIFO forces you to sell older, lower-cost lots first, potentially producing gains even in a downturn
- Specific ID lets you target lots above your sale price to harvest losses strategically
Taxpayers using dollar-cost averaging accumulate many lots at varying prices over time. For DCA buyers, HIFO is typically the most advantageous method because it automatically selects the most expensive lot regardless of purchase date. Use the crypto cost basis calculator to model how different methods affect your specific holdings.
IRS Rules and the 2025 Transition
The regulatory landscape for crypto cost basis changed significantly in 2024 and 2025. The Infrastructure Investment and Jobs Act of 2021 required brokers to report digital asset transactions on the new Form 1099-DA. The IRS finalized these rules in TD 9989 (July 2024), establishing several key requirements:
- Brokers must report gross proceeds for the 2025 tax year and adjusted cost basis starting in 2026
- FIFO is the default method applied per-wallet and per-account
- Each exchange account, self-hosted wallet, and cold storage device is treated as a separate ledger: lots cannot be mixed across wallets
- Revenue Procedure 2024-28 provided a one-time safe harbor for taxpayers to reallocate unused basis across wallets as of January 1, 2025
Because most brokers were not ready to accept specific identification instructions, the IRS issued Notice 2025-7 (January 14, 2025) granting temporary relief. This allows taxpayers to use specific identification (including HIFO and LIFO ordering) by recording standing instructions in their own books and records, without notifying the broker. Notice 2026-20 (March 18, 2026) extended this relief through December 31, 2026.
Important: Under this relief, the basis on your Form 1099-DA (calculated using FIFO by the broker) may differ from what you report on your tax return. You must retain documentation explaining any discrepancy.
Per-Wallet Tracking Requirements
Before 2025, many taxpayers and tax software platforms used "universal" tracking: treating all Bitcoin holdings across every wallet and exchange as a single pool. Under the final regulations (Treasury Regulation section 1.1012-1(j)), this is no longer permitted. Each wallet or account is a separate cost basis ledger.
This has practical implications. Two identical 1 BTC positions in different wallets can produce different tax outcomes. A lot purchased at $20,000 in Wallet A cannot be matched against a sale from Wallet B. For users who hold Bitcoin across multiple self-custodial wallets, cold storage devices, and exchange accounts, this requires granular record-keeping per location.
For a deeper look at how to track cost basis across wallets and exchanges, see the stablecoin accounting and tax guide, which covers similar per-asset tracking principles.
International Cost Basis Rules
Cost basis methods are not universal. The IRS allows FIFO and Specific Identification, but other tax authorities mandate entirely different approaches:
| Country | Allowed Method | Holding Period Benefit | Key Rule |
|---|---|---|---|
| United States | FIFO (default), Specific ID | Long-term rate (0%/15%/20%) after 12 months | Per-wallet tracking mandatory from 2025 |
| United Kingdom | Same-day, 30-day, Section 104 pool | Annual CGT allowance | FIFO not available: must use HMRC share pooling |
| Canada | Adjusted Cost Base (weighted average) | 50% inclusion rate on capital gains | Superficial loss rule (61-day window) |
| Australia | FIFO (default), Specific ID for investors | 50% CGT discount after 12 months | Must apply method consistently |
| Germany | FIFO only | Tax-free after 1-year holding period | EUR 1,000 annual de minimis threshold |
| France | Proportional portfolio formula | None | 30% flat tax on crypto gains |
Applying the wrong country's method produces a non-compliant return. UK residents cannot use FIFO: HMRC requires a hierarchical matching system (same-day rule, then 30-day bed-and-breakfasting rule, then Section 104 average pooling). Canadian taxpayers must use the Adjusted Cost Base weighted average for all holdings of the same asset. German taxpayers benefit from a complete tax exemption on gains from crypto held over one year, making FIFO (which Germany mandates) the natural fit.
Record-Keeping Requirements
If you use any method other than FIFO, you are performing specific identification and must maintain contemporaneous records. The IRS expects:
- Date and time of every acquisition
- Cost basis per lot (including transaction fees)
- Wallet or account identifier for each lot
- Date and time of every disposition
- Explicit mapping of each disposal to specific acquisition lots
- Fair market value at time of disposal
- Standing instruction or per-transaction designation recorded before the disposal
A standing instruction for HIFO should include: the identification method (highest-cost-first), the wallet scope, the adoption date (preceding any covered sales), a revocation protocol, and record retention procedures. The IRS expects tax documents and full transaction histories to be retained for six years.
Crypto tax software such as Koinly, CoinLedger, CoinTracker, and TaxBit all support FIFO, LIFO, and HIFO as selectable options. However, selecting HIFO in software does not automatically satisfy the "adequate identification" standard. Taxpayers should maintain a separate written standing instruction documenting their lot-selection policy. Use the crypto tax calculator to estimate your liability under different methods.
Frequently Asked Questions
Can I switch cost basis methods between tax years?
Yes. Cost basis lot selection is not considered an "accounting method" under IRC section 446, so switching does not require IRS approval via Form 3115. You can change methods prospectively between tax years. However, you cannot retroactively recharacterize prior-year dispositions, and you must apply a single method consistently within each wallet or account for the entire tax year. Different wallets may use different methods in the same year.
Is HIFO legal for Bitcoin taxes?
Yes, but HIFO is not a standalone IRS-approved method. It is a lot-selection strategy implemented through valid Specific Identification. Under Treasury Regulation section 1.1012-1(c), you must have contemporaneous documentation showing a standing instruction to relieve the highest-cost lot first, recorded before each disposal occurs. Selecting "HIFO" in tax software alone does not satisfy this requirement.
What is the IRS default cost basis method for cryptocurrency?
FIFO (First In, First Out). Under the 2024 final regulations (TD 9989), if a taxpayer does not make a valid specific identification, the IRS applies FIFO on a per-wallet, per-account basis. Starting with the 2025 tax year, brokers report on Form 1099-DA using FIFO as the default. Taxpayers can override this by using specific identification with proper documentation.
What is the difference between universal and per-wallet cost basis tracking?
Universal tracking treats all your Bitcoin across every wallet and exchange as a single pool. Per-wallet tracking treats each wallet or account as a separate cost basis ledger. As of January 1, 2025, per-wallet tracking is mandatory under Treasury Regulation section 1.1012-1(j). Lots from Wallet A cannot be matched against sales from Wallet B. Revenue Procedure 2024-28 provided a one-time safe harbor to reallocate basis when transitioning to per-wallet tracking.
Which cost basis method saves the most on taxes?
HIFO typically minimizes recognized gains because it sells the highest-cost lots first. In a bull market where all lots are profitable, HIFO produces the smallest gain per sale. However, the optimal method depends on your marginal tax rate, the holding period of each lot, and whether you want to preserve low-cost lots for future long-term treatment. In some cases, selling a lower-cost long-term lot at the 15% capital gains rate beats selling a higher-cost short-term lot at the 37% ordinary income rate.
Do I need to notify my exchange to use specific identification?
Eventually, yes. Under the final regulations, specific identification requires notifying your broker before the disposal. However, IRS Notice 2025-7 and Notice 2026-20 provide temporary relief through December 31, 2026: taxpayers can use specific identification by recording their standing instruction in their own books and records, without notifying the broker. After this relief expires (expected January 1, 2027), broker notification will be required.
Does cost basis method apply to stablecoins and other crypto?
Yes. The IRS treats all digital assets as property under Notice 2014-21. The same FIFO default and specific identification rules apply to stablecoins, altcoins, and tokens. Stablecoins typically have minimal gains or losses due to their dollar peg, but they still generate taxable events when disposed. For stablecoin-specific considerations, see the stablecoin accounting and tax guide.
This tool is for informational purposes only and does not constitute tax or financial advice. Tax laws vary by jurisdiction and change frequently. The IRS rules described reflect guidance through Notice 2026-20 (March 2026). Consult a qualified tax professional for advice specific to your situation. Always verify current regulations before filing.
Build with Spark
Integrate bitcoin, Lightning, and stablecoins into your app with a few lines of code.
Read the docs →
