Skip to main content

Crypto loans, repayments and collateral

Written by Jack

This article explains how Koinly treats loans, be it in crypto or fiat, and repayments of those loans, as well as collateral provision.

🪙 Crypto loans

Borrowing crypto

In Koinly, a receipt of a loan in crypto is considered an acquisition, equivalent to purchasing crypto at market price.

As such, a receipt of loan doesn't require any tags, but you can tag it as Loan (which doesn't change its behavior)

Repaying crypto

Repayment of a crypto loan in Koinly is equivalent to a disposal (selling crypto to a 3rd party) - as such, it should appear as a withdrawal from your wallet. Note that crypto loan repayment, like any disposal, may generate capital gains (or losses), depending on the cost basis of the asset and its current market value.

There is no need to tag it, but you can tag it as Loan repayment (which doesn't change its behavior).

Loan fees

If you want to include fees you paid for receiving the loan in the "Costs and expenses" section, you have to tag those payments as Loan fee.

ℹ️ Splitting loan repayment from fees paid

If you paid the fee together with the repayment of the loan (ie. there's one joint withdrawal) - then you have to delete this withdrawal and create two withdrawals in its place - one for principal repayment (to be tagged as Loan repayment), one for fees paid (to be tagged as Loan fee).

💵 Fiat loans

Fiat-denominated loans (e.g. you borrowed USD, or EUR) do not generate any capital gains in Koinly, just like any other fiat-only transactions.

You may tag loan fees you paid as Loan fee to include them in the "Costs and expenses" section of your tax report.

🗄️ Collateral

Usually, in order to receive a loan, you need to back it with some of your funds. Those assets are usually moved out of your possession for the duration of the loan, and returned once the loan is repaid.

Collateral as a non-taxable event

If you believe provision of collateral is not taxable:

  1. Locate the transaction where you provided collateral (a withdrawal of your asset)

    1. Koinly will automatically skip collateral-related transactions for the majority of exchanges (CEXes) but will import collateral transactions from dapps. Since you don't consider it taxable, you don't have to add it manually.

  2. Tag it using the pool tag ("Add to Pool"), like in staking

  3. Locate the transaction where your collateral was returned to you (a deposit)

  4. Tag it using the pool tag ("Remove from Pool")

☝️ Collateral transactions need to add up

You can only receive ("Remove from Pool") as much collateral as you provided ("Add to Pool"). If you see any "missing purchase history" on those transactions after tagging them, then it usually means you made a mistake when adjusting previous transactions (missed a tag, or added a tag where you shouldn't).

Collateral as a taxable event

In some jurisdictions, provision of collateral will be considered taxable (sometimes it depends on specific terms&conditions, e.g. if the platform takes "complete & free" control over your assets).

If your collateral provision should be considered taxable:

  1. Locate the transactions where you provided collateral (a withdrawal)

    1. If there is no collateral transaction (e.g. because it was skipped) you have to add it manually.

  2. Don't tag it in any way, leave it as a normal withdrawal (disposal)

  3. Note the worth this withdrawal (fair market value)

  4. Locate the transaction where your collateral was returned to you (a deposit)

  5. Don't tag it in any way, leave it as a normal deposit (acquisition)

  6. You may need to adjust the worth of this deposit to match the worth of the asset when it was provided as collateral (what you noted in step 3) - if unsure, confirm it with your accountant

Collateral liquidation

If your collateral was sold automatically (to repay your loan), then this liquidation should be imported to Koinly as a trade - there's no need to tag it.

In the case of DeFi loans, this trade will not be imported because it happened on the smart contract where your collateral was, not in your wallet. To account for it, you will need to add it manually - as a trade in your pool wallet (where you sent the collateral).

You can read more about pool wallets in Staking and farming tokens.

Did this answer your question?