Free tool

Perpetual futures PnL and ROE calculator

Work out net profit or loss after fees and funding, return on margin and the break-even exit price from entry, exit, quantity and leverage.

Pre-trade estimate only, not investment advice. Use the exchange account for executable fees and liquidation prices.

Estimate

Net profit386.80 USDT
Return on margin (ROE)
+38.68%
Gain from price
400.00 USDT
Opening and closing fees
10.20 USDT
Funding paid
3.00 USDT
Break-even exit price
50,065.03 USDT
Exit price for the target ROE
52,566.28 USDT
Initial margin
1,000.00 USDT
Return is measured on initial margin (notional ÷ leverage). Fees are charged on the position value at entry and at exit; funding on the entry notional. Pre-trade estimate only, not investment advice. Use the exchange account for executable fees and liquidation prices.

Direct answer

What a futures trade actually makes is the gain or loss from price, less the opening fee, the closing fee and any funding paid while the position was open. This tool separates the three, works out the net result and the return on initial margin (ROE), and solves the break-even exit price and the exit price for a target return. It assumes one entry and one full exit; partial fills, slippage and liquidation along the way are not included.

Net result = price move − fees − funding

The unrealized PnL an exchange shows looks only at price: for a long it is (mark price − average entry) × quantity, and the reverse for a short. When the position closes, the opening and closing fees and the funding paid or received along the way come off, and what is left is the change in the account.

Fees are charged on the position's value at each execution: the opening fee on the entry notional, the closing fee on the exit notional, so a long that rises further pays a larger closing fee. Funding is exchanged at each settlement on the position value; when the rate is positive, longs pay shorts.

Gain from price = direction × (exit − entry) × quantity
Net result = gain from price − opening fee − closing fee − funding
  • Direction is +1 for a long and −1 for a short.
  • Opening fee = entry × quantity × opening rate; closing fee = exit × quantity × closing rate.
  • Funding = entry notional × rate per interval × intervals × direction; a negative result is funding received.

Why ROE looks so large

The return an exchange displays is measured against margin: OKX's PnL rules define the PnL ratio as profit or loss divided by initial margin. Initial margin is notional divided by leverage, so the same price move produces a larger return at higher leverage — and a loss is magnified the same way.

A 4% rise gives a 10× long a 40% return before costs; the same 4% against it is roughly −40%. ROE measures what happened to the margin, not whether the trade was cheaper: fees and funding are charged on the notional and do not shrink as leverage rises.

Initial margin = entry × quantity ÷ leverage
Return on margin (ROE) = net result ÷ initial margin

Break-even: earning back the costs first

From the moment it opens, a position carries its opening fee; exiting without a loss also means paying the closing fee, and funding if it crosses a settlement. The break-even exit price is the one at which the net result is exactly zero.

A long breaks even above its entry and a short below it. With 0.05% taker fees on both sides, a long needs a rise of about 0.1% before it makes anything, and funding paid pushes the break-even further out. When setting a take-profit or judging a short-term strategy, start from the break-even price, not the entry.

Long break-even = [entry × (1 + opening rate) + funding ÷ quantity] ÷ (1 − closing rate)
Short break-even = [entry × (1 − opening rate) − funding ÷ quantity] ÷ (1 + closing rate)

Solving the exit price for a target return

To find how far price must rise for a 50% return, multiply the target ROE by the initial margin to get the net amount to earn, and add it to the break-even formula. The table uses the conditions of the worked example below: a 10× long entered at 50,000 USDT, 0.2 BTC, 0.05% fees on each side and 3 USDT of funding paid.

A target price is arithmetic, not a forecast. It is useful for checking a take-profit: at 10× leverage a 100% return needs a rise of about 10.14%. If a target needs a far larger move than the strategy usually captures, or lies further from entry than the liquidation price, reconsider the size or the leverage.

Long target exit = [entry × (1 + opening rate) + funding ÷ quantity + target ROE × entry ÷ leverage] ÷ (1 − closing rate)
Target ROEExit price (USDT)Rise needed
0% (break-even)50,065.030.13%
10%50,565.281.13%
25%51,315.662.63%
50%52,566.285.13%
100%55,067.5310.14%

When the exchange shows a different number

An exchange usually lists fees and funding separately from realized PnL, and computes unrealized PnL from the mark price. To reconcile, enter the same position's average entry, average exit, quantity, the maker or taker rate actually charged and the funding records, one by one.

Closing in parts, filling in parts, or paying fees in BNB or another asset all make the exchange's figures differ from this single calculation. Where they differ, the account's trade and funding records are authoritative.

  • Check whether each fill was maker or taker: a limit order that executes on arrival is charged as a taker.
  • Funding is paid or received only if the position is open at a settlement, so time held does not convert directly into intervals.
  • Coin-margined contracts settle profit in the coin; this tool covers USDT-margined contracts only.

Worked example

Reproducible example: a 10× BTCUSDT long closed 4% higher

A BTCUSDT long of 0.2 BTC opened at 50,000 USDT (10,000 USDT notional) at 10× leverage, held across 3 funding settlements and closed in full at 52,000 USDT, with both trades executed as taker.

Input
Entry 50,000 USDT, exit 52,000 USDT, quantity 0.2 BTC
Input
Leverage 10×, initial margin 1,000 USDT
Input
Opening and closing fee 0.05% each (example rates)
Input
Funding +0.01% per interval for 3 intervals (example rate)
Step 1
Gain from price = (52,000 − 50,000) × 0.2 = 400 USDT
Step 2
Fees = 10,000 × 0.05% + 10,400 × 0.05% = 5 + 5.2 = 10.2 USDT
Step 3
Funding = 10,000 × 0.01% × 3 = 3 USDT (paid by the long)
Step 4
Net result = 400 − 10.2 − 3 = 386.80 USDT; ROE = 386.80 ÷ 1,000 = 38.68%
Step 5
Break-even = (50,000 × 1.0005 + 3 ÷ 0.2) ÷ 0.9995 = 50,065.03 USDT

After costs the trade makes 386.80 USDT, a 38.68% return on margin; it starts making money only above an exit of 50,065.03 USDT.

The 0.05% and +0.01% rates are example values chosen to be recomputed, not the current rates of any exchange or account. The exchange's trade records show the fee tier, funding and fills that actually applied.

Frequently asked questions

How does ROE differ from a PnL percentage?

ROE divides by margin. A PnL percentage measured on the notional differs from it by exactly the leverage: in the example the notional gains 3.87%, which at 10× is a 38.68% return on margin.

How is a short's profit or loss worked out?

The price move runs the other way: a short gains as price falls. The same 0.2 BTC short opened at 50,000 USDT and closed at 52,000 USDT loses 400 USDT on price; after fees, and adding back the 3 USDT of funding it receives, the net loss is 407.20 USDT.

Why is the closing fee larger than the opening fee?

Fees are charged on the position's value at execution. After the rise, the long exits at a notional of 10,400 USDT, so the closing fee of 5.2 USDT exceeds the 5 USDT paid to open.

Does higher leverage make more money?

For the same position size, leverage changes only the margin tied up; the net result in USDT is unchanged. ROE grows because the divisor shrinks. Higher leverage also brings the liquidation price closer, so a small move against the position can end it before the target is reached.

Should the take-profit sit at the break-even price?

Break-even is only the point of no gain or loss; a take-profit belongs where the strategy says. Starting from break-even avoids a take-profit that looks profitable but loses money after costs.

Evidence

Official sources and checks

Each formula and exchange rule links to the official documentation, so you can check it yourself.

How this page was produced: Drafted with AI assistance · worked examples and links checked automatically before publishingLast updated

Related calculators