OKX logo
Koinly Logo

How To Do Your OKX Taxes With Koinly

Connect OKX (OKEx) with Koinly to calculate your crypto tax

Formerly OKEx, OKX is a popular, global crypto exchange, allowing millions of crypto investors in more than 100 countries access to a variety of investment opportunities including spot trading, crypto derivatives trading, perpetual swaps trading, DeFi, lending, and mining services. Whatever your investments, Koinly can help with your OKX taxes.

How are OKX transactions taxed?

Crypto tax varies - a lot - depending on where you're located. This said, in general, you'll pay two kinds of tax on your OKX investments - Income Tax or Capital Gains Tax:

  • Capital Gains Tax: Whenever you sell or swap crypto on OKX, you'll likely pay Capital Gains Tax on any profit from that transaction.
  • Income Tax: If you're earning new tokens through OKX products - like lending pools, staking, or with an OKX Savings account - then you'll pay Income Tax based on the fair market value of new tokens or coins on the day you receive them, in your fiat currency.

Want to learn more about crypto tax in your country? See our crypto tax guides.

Does OKX provide tax documents?

No. OKX does not provide tax documents for users. Instead, you'll need to get your OKX transaction history and either calculate your OKX taxes yourself, or use crypto tax software to do it for you.

How to get your OKX tax report with Koinly

OKX offers two simple ways to get the tax documents you need - you can either use the OKX tax API to connect to Koinly or export a CSV of your OKX transaction history and upload that to Koinly.

Once connected, Koinly becomes the ultimate OKX tax tool. How? Koinly will calculate your OKX taxes based on your location and generate your crypto tax report, all within 20 minutes. All you’ll need to do at tax time is download the crypto tax report you need from Koinly and file it with your local tax authority.

How to connect OKX to Koinly via API

On OKX

  1. Log in to OKX.
  2. In the top right corner, select your profile icon.
  3. From the drop down menu, select API.
  4. Enter a name for your API, for example, Koinly.
  5. Create a passphrase - you'll need to remember this later when connecting to Koinly.
  6. Under permissions, check read.
  7. Select get code next to email code. Go to the email address associated with your OKX account to get the code, and copy and paste it into the box. You may also need to verify via an authentication app - like Google Authenticator App.
  8. Select confirm.
  9. Copy your API key and API secret key.

On Koinly

  1. Sign up or log in to your Koinly account and go to the wallets page.
  2. Select add new wallet: OKX (OKEx).
  3. Select set up auto-sync.
  4. Paste the API key and API secret into Koinly.
  5. Enter your passphrase you created earlier.
  6. Select secure import.

Good to know
You'll need a V5 API key from OKX to connect with Koinly. The API has some limitations - including limiting trading history to the last 3 months and other transaction history is limited to the past month. So you may prefer to use the CSV file method to get your complete transaction history for Koinly.

How to connect OKX to Koinly via CSV

You need a couple of CSV files from OKX to get your complete transaction history - the Trading Account History CSV file and the Funding Account History CSV file. Here's how to get both:

On OKX

For Trading Account History CSV:

  1. Log in to your OKX account.
  2. Select assets in the top right corner.
  3. From the drop down menu, select my assets.
  4. Select order center.
  5. Select trading account history.
  6. Select download.
  7. Click on a select date range, then select customize. You'll then be able to pick a custom date range for your CSV transaction data. Your selected date range should cover your entire trading history on OKX.
  8. Select export.

For Funding Account History CSV:

  1. Log in to your OKX account.
  2. Select assets in the top right corner.
  3. From the drop down menu, select my assets.
  4. Select order center.
  5. Select funding account history.
  6. Select download.
  7. Click on a select date range, then select customize. You'll then be able to pick a custom date range for your CSV transaction data. Your selected date range should cover your entire trading history on OKX.
  8. Select export.

On Koinly

  1. Sign up or log in to your Koinly account and go to the wallets page.
  2. Select add new wallet: OKX (OKEx).
  3. Select import from file.
  4. Upload your CSV files.

Good to know
As there are limits to the amount of transaction history you can export at one time from OKX, you may need multiple CSV files to cover your entire transaction history on OKX. Koinly needs your complete transaction history, for however long you've been using OKX, in order to calculate your crypto taxes correctly.

Does OKX report to tax offices?

OKX requires KYC in order to access all the trading features available. As a large, centralized exchange, it is possible OKX may face pressure from tax offices around the world to share this customer data in order to ensure tax compliance.

How do I check if my OKX import is accurate?

If you're having trouble connecting OKX and Koinly, these resources will help:

It's really helpful to use our Getting Started Guide before reviewing your transactions. This can help you identify and resolve any issues in no time at all.

Does OKX have Proof of Reserves?

Yes - OKX has provided Proof of Reserves via a Merkle Tree to their users. OKX lets users verify that their deposits are held 1:1 by publicly outlining a list of their on-chain wallets, as well as regular publishing of audits of their crypto balances. For more information about what Proof of Reserves are and why it matters - check out our blog post.