Skip to main content

Formatting Perpetuals/Futures CSVs

Written by Andrew Duca

Overview

Before diving in, take a look at the sample CSV provided, and watch our quick tutorial video below.

Sample CSV:


Download the Example CSV

To streamline the process, download the example CSV at the bottom of this guide.


General Formatting Tips

For perpetuals CSVs, the format is different from other types of crypto trading CSVs.

Our CSV for perpetuals has a few components:

  1. A P&L column for you to add the profit/loss from the perps trade

  2. The token you received the profit/loss in (usually fiat or a stable coin)

  3. The underlying asset the perpetual is related too (ex. Fartcoin or Bitcoin)


Perpetuals CSVs Example

If the platform you are trading perpetuals in gives you the P&L, you'll want to make your CSV look like this:

  1. Row 1: You opened a position shorting 2 BTC

    1. Date: April 1st, 2024

    2. Asset: Bitcoin

    3. Amount: 1

    4. P&L: 0

    5. Tag: open_position

  2. Row 2: You closed your position shorting 1 BTC and made 20 USDC

    1. Date: April 2nd, 2024

    2. Asset: Bitcoin

    3. Amount: 1

    4. P&L: +20

    5. Payment Token: USDC

    6. Tag: close_position

  3. Row 3: You received a funding payment of $10

    1. Date: April 4th, 2024

    2. Asset: USDC

    3. Amount: 10

    4. P&L: 10

    5. Payment Token: USDC

    6. Tag: funding_payment


CSV Requirements

  • Columns:

    • Date: the date, Use MM/DD/YYYY HH:MM:SS in UTC time. for example: 09/30/2019 07:19:01

    • Asset: the underlying perpetuals asset, ex. BTC or Fartcoin.

    • Amount: the amount of the underlying asset, ex. 10 (for Bitcoin)

    • Fee: the fee, in the payment token (below)

    • P&L: the net P&L from the trade. Can be negative, positive, or zero (if no P&L)

    • Payment Token: the token that P&L is settled in, usually USDC, USDT (stablecoins) or a fiat currency

    • Notes: optional, any notes about the trade

    • Transaction Hash: a hash for the trade

    • Tag: a tag, either "open_position", "close_position", or "funding_payment"

  • Header Row: Match it precisely with the example provided.

  • Date Format: Use MM/DD/YYYY HH:MM:SS in UTC time. for example: 09/30/2019 07:19:01

  • Decimal Precision: Up to eight decimal places for numbers.

  • IMPORTANT:

    • Avoid Duplicates: Importing the CSV multiples times may lead to duplicates.

Attachment icon
Did this answer your question?