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.
- 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.
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.
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.
| Target ROE | Exit price (USDT) | Rise needed |
|---|---|---|
| 0% (break-even) | 50,065.03 | 0.13% |
| 10% | 50,565.28 | 1.13% |
| 25% | 51,315.66 | 2.63% |
| 50% | 52,566.28 | 5.13% |
| 100% | 55,067.53 | 10.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.
Unrealized PnL from the average open price; PnL ratio = PnL ÷ initial margin
Recorded: 2026-10-07Trading fee = position value × fee rate, with position value at the execution price
Recorded: 2026-10-07USDT-margined fee = contract value × contracts × execution price × fee rate
Recorded: 2026-10-07Funding is exchanged at settlement on the position value; longs pay when the rate is positive
Recorded: 2026-10-07
How this page was produced: Drafted with AI assistance · worked examples and links checked automatically before publishingLast updated