1. How the calculator works: the formulas
Every linear (USDC- or USDT-settled) perpetual future uses the same arithmetic; only the fee schedule and the funding interval change between venues. Hyperliquid's documentation defines unrealized PnL as side × (mark price − entry price) × position size and the closed PnL of a fill as fee + side × (price − entry price) × closed size; only the fee on an opening trade. The calculator applies that to a full round trip and adds funding:
Gross PnL = side × (exit price − entry price) × quantity (side = +1 long, −1 short)
Fees = entry notional × entry fee rate + exit notional × exit fee rate
Fee rate = venue rate (tier, maker or taker) × (1 − staking discount) × (1 − referral discount)
Funding = side × entry notional × funding rate per interval × hours held ÷ interval
Net PnL = gross PnL − fees − funding (funding < 0 means you receive it)
Initial margin = entry notional ÷ leverage; ROE = PnL ÷ initial margin
Break-even exit (long) = (entry notional + entry fee + funding) ÷ (quantity × (1 − exit fee rate))
Break-even exit (short) = (entry notional − entry fee − funding) ÷ (quantity × (1 + exit fee rate))
- quantity
- coins: size in coins, or USD notional ÷ entry, or USD margin × leverage ÷ entry
- notional
- quantity × price (the fee and funding base, never the margin)
- interval
- hours between funding payments: 1 on Hyperliquid, 1 on Lighter, 4 on edgeX, 8 on BTC at Aster, 8 at Binance and 8 at Bybit
- Fees are charged on notional, the quantity times the fill price, never on your margin. The exit fee uses the exit price, so a winning long pays slightly more to close than to open.
- Discounts multiply. On Hyperliquid the tier rate is multiplied by (1 − HYPE staking discount) and by (1 − 4%) with a referral code. The referral discount covers only an account's first $25M of volume, so at fee tiers whose 14-day threshold is above that it is not applied, the same rule as our Hyperliquid calculator and Hyperliquid fee calculator. On Lighter Premium the LIT staking discount multiplies both rates; on Binance the BNB discount does.
- Funding follows the venue. The rate box takes the rate per funding interval as the exchange shows it (an hourly rate on Hyperliquid, an 8-hour rate on Binance). Empty, it uses the 0.01% per 8 hours interest baseline scaled to the interval (0.00125% an hour). Funding is spread pro rata: hours held ÷ interval payments, which is the average number of settlements a hold of that length crosses. Only positions open at a funding time pay, so when the hold is not a whole number of intervals the result also shows the whole payments it can actually catch (a 6-hour hold on an 8-hour venue: 0 or 1), the same range as the funding rate calculator.
- Liquidation is checked. For Hyperliquid, Lighter, Aster and edgeX the calculator works out the isolated liquidation price from the BTC market's maintenance margin (Hyperliquid: half the initial margin at max leverage, 50%; Lighter: 60% of the initial margin fraction; Aster and edgeX: their bracket and tier rates), also after the funding paid over the hold, with the same code as the liquidation price calculator. An exit at or beyond it is flagged: the position is closed by the venue first, well before the loss reaches the whole margin.
- Break-even and targets are solved exactly, with the exit fee charged at the solved price, so a trade closed at the break-even exit nets zero after both fees and funding.
2. Worked examples (same code as the calculator; BTC mark of October 20, 2026, 03:53 UTC)
Long BTC on Hyperliquid, 10x, market orders, 24 hours
$10,000 of BTC at $82,073 is 0.12184 BTC. At 10x the initial margin is $999.98. A 5% rise to $86,177 makes $500.03 gross, an ROE of +50%. The entry fee is $4.32 and the exit fee $4.54 (0.0432% each: 0.045% taker less the HOLYGRAIL discount); without the code the two fees would be $9.22. Funding at the 0.00125%/hour baseline costs $3.00 over 24 hours. Net: $488.18, +48.82% on the margin. The trade breaks even at $82,168.57, 0.12% above entry.
Short BTC: Binance vs Hyperliquid, 48 hours
The same $10,000 short, closed 5% lower after 48 hours, makes $500.04 gross on both. On Binance USDⓈ-M (Regular, 0.05% taker) the fees are $9.75; on Hyperliquid with HOLYGRAIL $8.42. At a positive funding rate the short receives funding: $6.00 over the hold on both venues at the baseline, settled in 6 payments of 8 hours on Binance and 48 hourly ones on Hyperliquid. Net: $496.29 on Binance, $497.61 on Hyperliquid.
Limit orders on both sides
Resting limit orders pay the maker rate (0.015% at Hyperliquid tier 0, a third of the taker rate). The same long with code HOLYGRAIL and maker entry and exit pays $2.95 in fees instead of $8.86 and nets $494.08. On Lighter's Standard account both rates are zero, so the same trade nets $497.04 (funding only), and on Aster, where makers pay 0%, a 6-hour hold settles 0.75 of an 8-hour funding payment on average.
Leverage and targets
At 20x the same $10,000 position needs $499.99 of margin and shows +100.01% ROE, but the dollar result is unchanged at $488.18. To make +100% ROE at 10x the price must reach $90,280.30 on the price move alone, or $90,379.42 once both fees and funding are paid. A smaller goal, $250 net, needs $84,221.33 (+2.62%): the costs add about the same dollar amount to every target, so they matter most for small ones.
The fee line is the part of PnL you control
Hyperliquid with HOLYGRAIL: 0.0432% taker / 0.0144% maker at tier 0, hourly funding, the deepest on-chain order book.
3. Venue rules the calculator applies
| Venue | Taker / maker | Discounts | Funding | Funding cap | Min order |
|---|---|---|---|---|---|
| Hyperliquid | 0.045% / 0.015% (tier 0) down to 0.024% / 0% (tier 6) | HYPE staking −5% to −40%; referral −4% on the first $25M | Every 1 h, oracle price | 4% per 1 h | $10 |
| Lighter | Standard 0% / 0%; Premium 0.028% / 0.004% | Premium only: LIT staking −2.5% to −30% | Every 1 h, index price | 0.5% per 1 h | $10 |
| Aster (Pro) | 0.04% taker (VIP 1) to 0.016% (VIP 6); 0% maker | VIP levels need 14-day volume and an ASTER balance | 8 h on BTCUSDT, ETHUSDT, SOLUSDT and other majors; 4 h on most other markets; 1 h on some | 0.3% per 8 h (BTCUSDT) | 5 USDT |
| edgeX | 0.045% / 0.04% (Regular) to 0.020% / 0.015% (VIP 6) | VIP 1–6 by 14-day volume | Every 4 h, index price | 0.2% per 4 h (BTCUSDC) | per-coin minimum size |
| Binance USDⓈ-M | 0.05% / 0.02% (Regular) | −10% paying in BNB | BTCUSDT every 8 h | 0.3% per 8 h (BTCUSDT) | — |
| Bybit | 0.055% / 0.02% (Non-VIP) | VIP levels | BTCUSDT every 8 h, mark price | 0.333% per 8 h (BTCUSDT) | — |
Fee schedules and intervals from each venue's docs, VIP pages and public APIs (dates under Sources). Hyperliquid's funding cap applies to every market; Lighter's 0.5% an hour is the value its docs give for the majority of markets (they also scale the premium down on RWA and pre-market listings). The calculator enforces both, and the Aster, edgeX, Binance and Bybit caps of the BTC market it models (a venue never settles above its cap; other markets have their own). Hyperliquid leverage is a whole number (leverage is any whole number from 1x to the asset's maximum, checked only when the position is opened) up to the market's maximum for the position size (BTC: 40x up to $150M, 20x above), so the calculator rounds it down and caps it there, and rounds the size down to the BTC lot, as our Hyperliquid calculator does. On the other venues a leverage above the BTC market's maximum (Lighter 50x, Aster 200x on the first $400 and 150x up to $300,000, edgeX 100x up to $1M) is flagged.
Two details change real results. Hyperliquid charges funding on the oracle price, Lighter and edgeX on the index price, Bybit on the mark price; the calculator uses your entry notional for all of them, which is exact only if the price does not move. And funding on interval venues settles only for positions open at the settlement time (edgeX's docs: position size × index price × funding rate, paid only by positions held at the settlement time): close a minute before an 8-hour settlement and you pay nothing for that interval. Aster's rate is the 8-hour formula divided by (8 ÷ funding interval), so a 4-hour market's rate is already half an 8-hour rate.
4. Leverage, margin and ROE
Leverage decides how much margin backs a position, not how much it makes. A $10,000 position earns the same $500.03 on a 5% move at 2x and at 40x, Hyperliquid's BTC maximum; what changes is the margin ($5,000 vs $249.99) and therefore ROE. That is why "10x profit" on a futures screenshot is usually ROE, and why fees look small in dollars but large against margin: the $9.22 Hyperliquid round trip above is 0.92% of a 10x margin. Size positions from your stop distance with the position size calculator, and check the liquidation price before you add leverage. For how Hyperliquid itself displays unrealized PnL, Closed PNL and funding, read how Hyperliquid calculates PnL.
5. Limitations
- An estimate, not trading advice. Spread, slippage and price impact are not included; enter your expected average fill prices as entry and exit. The liquidation check is for an isolated position on the BTC market's tiers (cross margin depends on the whole account), and none is shown for the Binance, Bybit and custom presets.
- Funding is held constant at the rate you enter and charged on the entry notional; real rates change every interval.
- Entry-level fee schedules for the comparison table; Hyperliquid builder fees charged by third-party apps (Based, Liquid, fomo and others) are extra and not modelled. The HOLYGRAIL discount itself still applies to orders through apps you connect with the same wallet, such as Based or Liquid. Not in fomo: fomo has no wallet connection (Apple, Google or email only) and creates its own wallet and Hyperliquid account for you, so a Hyperliquid code such as HOLYGRAIL cannot apply there.
- Linear USDC/USDT contracts only. Coin-margined (inverse) contracts and CME futures priced in ticks per contract follow other formulas.
Comparing fee schedules by month rather than per trade? Use the DEX fee calculator.
Sources (official pages behind every figure, with the date each was last verified in our facts registry)
- api.bybit.com/v5/market/instruments-info (verified October 14, 2026 · 3 figures)
- app.hyperliquid.xyz/trade (verified September 27, 2026)
- docs.asterdex.com/program-and-rewards/vip-program (verified October 15, 2026)
- docs.asterdex.com/trading/perpetuals/fees-and-specs/fees (verified October 19, 2026)
- docs.asterdex.com/trading/perpetuals/fees-and-specs/funding-rate (verified October 1, 2026)
- docs.lighter.xyz/trading/contract-specifications (verified October 14, 2026)
- docs.lighter.xyz/trading/funding (verified October 19, 2026 · 2 figures)
- docs.lighter.xyz/trading/trading-fees (verified September 26, 2026 · 3 figures)
- edgex-1.gitbook.io/edgeX-documentation/trading/funding-fees (verified October 1, 2026)
- edgex-prod-v2.edgex.exchange/api/v2/public/meta/getMetaData (verified October 14, 2026 · 4 figures)
- fapi.asterdex.com/fapi/v1/fundingInfo (verified October 1, 2026 · 3 figures)
- fapi.binance.com/fapi/v1/fundingInfo (verified October 19, 2026 · 2 figures)
- hyperliquid.gitbook.io/hyperliquid-docs/for-developers/api/error-responses (verified September 26, 2026)
- hyperliquid.gitbook.io/hyperliquid-docs/referrals (verified October 19, 2026 · 2 figures)
- hyperliquid.gitbook.io/hyperliquid-docs/trading/entry-price-and-pnl (verified October 19, 2026 · 2 figures)
- hyperliquid.gitbook.io/hyperliquid-docs/trading/fees (verified October 1, 2026 · 3 figures)
- hyperliquid.gitbook.io/hyperliquid-docs/trading/funding (verified October 19, 2026 · 3 figures)
- hyperliquid.gitbook.io/hyperliquid-docs/trading/liquidations (verified October 1, 2026)
- hyperliquid.gitbook.io/hyperliquid-docs/trading/margin-tiers (verified October 14, 2026 · 2 figures)
- hyperliquid.gitbook.io/hyperliquid-docs/trading/margining (verified October 1, 2026)
- mainnet.zklighter.elliot.ai/api/v1/orderBookDetails (verified September 26, 2026 · 2 figures)
- pro.edgex.exchange/ja-JP/vip (verified October 14, 2026)
- pro.edgex.exchange/vip (verified October 14, 2026)
- asterdex.com/bapi/futures/v1/friendly/future/common/brackets (verified October 14, 2026 · 2 figures)
- binance.com/bapi/futures/v1/friendly/future/common/brackets (verified October 15, 2026)
- binance.com/en/fee/futureFee (verified October 15, 2026)
- bybit.com/en/announcement-info/fee-rate (verified October 15, 2026)
- bybit.com/en/help-center/article/Funding-fee-calculation (verified October 1, 2026)