Kraken records trade execution separately from changes to account balances
Kraken spot trades can be reconciled by comparing execution records with ledger entries for each affected currency balance. Trades history supplies prices, quantities and execution costs. Ledger history shows the actual debits, credits and fees, so both views explain why a completed trade changed the balances.
Last updated ·
Execution price, volume and cost use different units
A spot execution record expresses price and cost in the quote currency, with volume in the base currency. The base currency is the asset being bought or sold, and the quote currency measures its exchange value. Price therefore means quote units per base unit, while volume means base units exchanged. Multiplying these values gives gross execution cost. For a purchase, that cost represents quote currency exchanged for the asset. For a sale, it represents quote currency proceeds before fees.
The cost field excludes trading fees. Treating it as the commission confuses the exchange value with Kraken’s charge.
Execution price belongs to the recorded fill, while a later portfolio valuation uses prices from another moment. Even when both figures use the same quote currency, they describe different events. A changing valuation alone does not establish another ledger debit or credit.
Order IDs and ledger references connect the records
Identifiers connect executions with balance entries without assuming that nearby timestamps describe the same event. In a Trades export, txid identifies an execution.
Executions belonging to the same order share an ordertxid.
A ledger row uses txid to identify its individual posting and refid to connect that posting with the underlying transaction, which allows related currency entries to be matched without confusing them with separate executions or orders. The ledgers field supplies associated ledger IDs when included in trade data.
An order’s total executed volume and cost come from its fill rows. Dividing total execution cost by total executed volume gives the volume-weighted price before fees. An unweighted average gives small and large fills equal influence. Grouping by order ID summarizes execution activity, but an unfilled remainder adds no executed quantity to those totals.
Why does the balance change differ from trade cost?
Ledger entries record the transaction amount and fee separately, so a purchase’s balance debit can exceed its trade cost. Each row concerns one asset, with separate amount and fee fields that record the debit or credit and the corresponding charge. A fee charged in quote currency increases the quote outflow from an unleveraged purchase. A base-currency fee reduces the net base-asset credit below the gross executed volume.
The fee in Trades history is a quote-currency estimate, even when the actual deduction uses base currency. Comparing raw fee numbers across currencies therefore gives a misleading result. The ledger identifies the actual fee asset and amount. A quote-currency fee value cannot be subtracted directly from a base-asset balance without accounting for the different units.
Fee currency selection is a preference that the exchange may not honor. Only certain pairs allow base-currency fee selection, and available balances can affect the deduction. The preference entered with the order does not establish which asset actually paid the fee.
A purchase with the fee charged in either currency
Changing the fee currency can move the deduction between balances while leaving the gross execution unchanged. This hypothetical, unleveraged purchase buys 2.415 base units at 113.75 quote units per base unit. The assumed fee has a value of 0.91 quote units. Both cases keep price and gross volume unchanged.
Before placing the order, the selected pair must support the requested fee currency. Available balances can also affect whether the preference is honored. The comparison applies when the actual fee deduction matches the assumed option.
With the fee charged in quote currency, gross cost is 2.415 × 113.75 = 274.70625 quote units, and adding the 0.91 fee makes the quote-balance debit 275.61625 units. The base balance gains 2.415 units.
If the fee instead comes from the base asset, its assumed value equals 0.008 base units at this price. The quote balance falls by 274.70625 units, while the net base credit becomes 2.415 - 0.008 = 2.407 units. Adding the displayed 0.91 quote-currency fee to this case’s quote outflow would invent an extra debit. The base-asset ledger fee explains the smaller credit despite an unchanged execution volume.
Ledger balances reconstruct the account over time
Ledger history provides a running balance for each asset after the recorded transaction has affected that asset. Using the signed amount, the relationship is new balance = old balance + amount - fee.
A ledger balance already includes the deduction of that entry’s fee.
Subtracting the fee again from that balance would count it twice. Across a reporting period, opening balance plus all signed amounts minus fees gives closing balance. Deposits, withdrawals and internal transfers can change balances without adding spot executions.
A historical balance comes from the last posting for that asset before the chosen cutoff. No transaction on the reporting date is necessary. A Balances export supplies a snapshot for a chosen date, whereas matched Trades and Ledgers exports cover a date range and retain the execution and posting details that explain movements during the period. Asset filters and omitted columns can hide part of that relationship. Full ledger exports reveal balances and dated activity, so share only the entries needed to discuss a discrepancy.
Purchase methods and margin use change the records
An app purchase and an order book execution can change balances without appearing in the same Trades export. Purchases through the Kraken app or Buy Crypto widget appear in Ledger history. Their spend entries record assets debited, and their receive entries record assets credited. These entries should not be treated as missing order book executions merely because the Trades export lacks a matching row. Their balance changes still belong in an account reconciliation.
Kraken provides the funds for an opening spot trade on margin, so execution cost is not deducted from your account balance. The margin field records the margin used in quote currency; zero denotes a non-margin trade. The trading fee’s currency preference does not apply to margin opening or rollover fees, so a reconciliation that groups every position charge under the ordinary trading fee would misstate which amounts belong to each charge.
Associated ledger IDs connect rollover charges with the trade that opened the margin position. Margin ledger amounts record profit or loss when all or part of a position closes; the amount is zero at opening. The opening entry’s fee field combines trading and margin opening fees, while rollover fees have separate entries.
Common questions
-
Why does the date disappear when I open a Trades CSV?
- A spreadsheet can display only the time even though the export contains the complete date and time. Kraken records both in the time field using UTC. Adjust the cell display to show the date as well. Inspecting the raw CSV distinguishes a hidden date from missing data, without changing the underlying transaction timestamp.
-
Which spreadsheet setting can distort small ledger amounts?
- The decimal separator must match the periods that Kraken uses in its CSV exports. A spreadsheet configured for decimal commas can misread those values during import. Changing the visible number format afterward may not repair the imported amount. If an incompatible application has saved changes, download a fresh copy and import it with compatible decimal settings.
-
What prevents double counting when history exports overlap?
- Deduplicate overlapping exports within each record type using the row’s transaction ID. Keep separate executions that share an order ID, since those rows can represent distinct partial fills. Likewise, matching ledger reference IDs connect related postings without making them duplicate rows. Trade rows and ledger rows describe different records, so retain their separate identifiers when combining files.
-
Does one successful API history response contain every matching record?
- A successful history response can contain only one page of matching records. The spot history endpoints support pagination and date filters. Trade history can be filtered by pair, while ledger history can be filtered by asset. In cursor mode, a returned next cursor indicates that more pages remain. Retrieve those pages before treating the collected history as complete for the selected range.
-
How is the trading fee percentage calculated from an execution row?
- Divide the quote-currency fee value in the trade row by its cost and multiply by 100 to express the ratio as a percentage. The denominator excludes fees. This calculation uses the fee estimate in Trades history and excludes margin opening fees or rollover charges. Ledger entries establish the currency and amount actually deducted.
-
Is a ledger transaction ID also a blockchain transaction hash?
- Ledger transaction IDs are internal account identifiers and are distinct from blockchain transaction hashes. Ledger exports omit blockchain addresses and hashes for cryptocurrency deposits and withdrawals. Those details belong to the funding transaction information. A ledger posting can support account reconciliation without supplying the identifier needed to locate a transfer on a blockchain explorer.
-
When is a requested history export ready to download?
- A history export is ready when its download control becomes enabled in the Documents Center. Creating the request starts report processing without immediately producing the downloadable file. Check the export list for its status rather than treating request submission as completion. A processing report does not establish whether a particular transaction is missing from the finished export.
-
Can a deposit ledger entry establish an asset’s original purchase cost?
- A deposit entry alone does not establish the original purchase cost of the deposited asset. It records the asset arriving in the account, without reconstructing an earlier acquisition elsewhere. The original acquisition records supply that information. The asset’s value on its deposit date and its original purchase cost describe different events, even when the deposited quantity is unchanged.