cryptonist
Fibre optic strands gathered into a bundle, their ends lit

DeFi

Perpetual futures: funding, margin and liquidation

A perpetual future is a contract on the price of an asset that never expires. Because no settlement date forces it back to the spot price, a periodic payment between the holders of long and short positions does that job instead. The rest of the design, from mark prices to margin, liquidation, insurance funds and auto-deleveraging, exists to stop a leveraged position from owing more than it holds and, when one does, to decide who absorbs the shortfall. What follows is the mechanism as two venues document it. It is not a case for trading one.

What replaces the expiry date

A dated futures contract converges on the spot price because it has to. At expiry it settles against the price of the underlying asset, so by that date the two have to meet. The US Commodity Futures Trading Commission’s policy statement on perpetual contracts, published in June 2026, starts from that point: a perpetual has no expiry through which to converge, so it needs a substitute.

The substitute is the funding rate. When the perpetual trades above the spot price, holders of long positions pay holders of short positions; when it trades below, shorts pay longs. The payments, in the statement’s words, are meant to give traders an incentive to arbitrage the gap away by taking whichever side is being paid. Funding moves between traders. Hyperliquid’s documentation says its funding is purely peer-to-peer and that no fees are collected on the payments.

The same statement says perpetuals have become a dominant form of crypto derivative trading worldwide, and that the market grew up mostly on venues outside the United States. That history comes back in the section on US rules.

How a funding rate is calculated

Venues differ in detail but share a shape: a premium, measuring how far the contract trades from the reference price, plus an interest component, sampled often and averaged before it is charged.

Hyperliquid. The premium compares the price at which a fixed notional amount could be bought or sold on the order book with the oracle price. It is sampled every five seconds and averaged over the hour. The formula gives an eight-hour rate: the average premium, plus the difference between a fixed interest rate and the premium, with that difference held within 0.05% either way. One eighth of the result is charged every hour. The interest rate is fixed at 0.01% per eight hours. The payment is the position size multiplied by the oracle price and the funding rate, so it is charged on the full notional value of the position. Funding is capped at 0.5% an hour, which the documentation calls much less aggressive capping than at centralised venues.

dYdX. The dYdX Chain documentation uses a similar premium measured against the index price, with the impact notional set by the market’s initial margin. The proposer of each block submits a premium vote, the median vote over each minute becomes that minute’s sample, and the hour’s samples are averaged. The hourly rate is the premium divided by eight plus an interest component, which the default software sets at zero for cross-margined markets. The eight-hour cap is 600% of the gap between initial and maintenance margin, 12% for a large-cap market such as BTC-USD, and governance can change the parameters that feed all of this.

Because funding is charged on notional value and margin is a fraction of it, the cost relative to the money actually put up scales with leverage. An illustration with invented numbers, not a forecast of any rate: a position worth $10,000 paying Hyperliquid’s fixed interest component alone, 0.00125% an hour, pays $0.125 an hour, $3 a day and $1,095 over a year if nothing changes. That is about 11% of the position’s value. If the position is held at ten times leverage on $1,000 of margin, the same payments exceed the margin within a year. Real rates change every hour and can turn negative.

Index, oracle and mark prices

A perpetual uses more than one price, and at both venues described here the one that triggers a liquidation is not the last trade.

The index or oracle price is the reference: an estimate of the spot price taken from outside the venue’s own order book. Hyperliquid’s validators compute it as a weighted median of spot prices from centralised exchanges, weighted by liquidity, and publish it roughly every three seconds. The point, its documentation on price indices says, is that it does not depend on Hyperliquid’s own market data at all.

The mark price is the venue’s estimate of the contract’s fair value. On Hyperliquid it is the median of three inputs: the oracle price adjusted by a moving average of the gap between the venue’s mid price and the oracle; the median of the best bid, best ask and last trade on Hyperliquid; and a weighted median of perpetual prices on other venues. Mark price is what Hyperliquid uses for margin, liquidations, stop orders and unrealised profit and loss, and its liquidation page warns that during high volatility it may differ significantly from the price on the book. dYdX uses the oracle price to value the positions in an account.

The reason for all of this is manipulation. Hyperliquid presents its price indices as a way to minimise the risk of market manipulation, and its liquidation page says that basing liquidations on a mark price that combines outside prices with the book’s state makes them “more robust than using a single instantaneous book price”. The CFTC statement makes the regulatory version of the point: a dated future needs a reliable reference price at one moment, its expiry, while a perpetual’s reference must be reliable at every funding interval for as long as the contract exists.

Margin and leverage

To open a position a trader posts initial margin; to keep it open the account must stay above maintenance margin. Leverage is the ratio of the position’s value to the margin behind it.

On Hyperliquid, the margin required to open is the position size multiplied by the mark price, divided by the chosen leverage, and maintenance margin is half the initial margin at the asset’s maximum leverage. The liquidation page gives maximum leverage of 3x to 40x depending on the asset, which puts maintenance margin between 16.7% and 1.25% of the position. dYdX publishes fractions by tier: 5% initial and 3% maintenance for large-cap markets, 10% and 5% for mid-cap, 20% and 10% for long-tail, and its margin page adds that the initial fraction rises towards 100% as open interest in a market grows past set limits.

Both venues offer cross margin, where every position shares the account’s collateral, and isolated margin, where a position has its own collateral and its liquidation does not touch the rest. Cross margin keeps a position alive longer by drawing on everything else, and so puts everything else at risk.

dYdX’s documentation gives the liquidation price of a position whose margin backs nothing else as a formula, and working it through shows how little room leverage leaves. An illustration with invented numbers: $1,000 of margin backs a long position of 100 units of an asset priced at $100, a position worth $10,000, at ten times leverage, with a 3% maintenance fraction. Liquidation arrives at about $92.78, a fall of 7.2%, not 10%, because the account must still hold 3% of the position’s value at that price. Funding paid in the meantime moves that price closer, and funding received moves it away.

What liquidation does

When an account drops below maintenance margin, the venue closes positions for it. How it does so decides what the trader keeps.

Hyperliquid first sends market orders to the order book for the whole position, or for 20% of it when the position is worth more than 100,000 USDC. If that brings the account back above maintenance margin, the trader keeps whatever collateral is left. If equity falls below two-thirds of maintenance margin without a successful close on the book, a backstop liquidation hands the positions and the margin to a liquidator vault that is part of Hyperliquid’s HLP vault. The maintenance margin is not returned, which the documentation explains as the buffer that makes backstop liquidations profitable for the vault on average. After a backstop liquidation of a cross-margin account with no isolated positions, the trader is left with nothing.

dYdX’s liquidation engine closes positions against the order book at a calculated limit price. Up to the account’s entire remaining value can be taken as a penalty, and the engine tries, where possible, to leave funds in an account once it has paid a maximum penalty of 1.5%. Penalties go to an insurance fund, which takes on the profits and losses of liquidations and which, the documentation notes, governance must first fund from the community treasury.

When collateral runs out: insurance funds and auto-deleveraging

A liquidation is supposed to happen while the account still has money in it. A fast enough move can skip that point and leave an account with negative value, a loss that belongs to nobody yet. Every venue needs a rule for whose loss it becomes.

dYdX describes two layers in its contract loss mechanism. The insurance fund can pay to improve a liquidation order’s price, up to a maximum distance from the oracle price, to give the order a better chance of filling. Once an account’s balance is negative, deleveraging happens at once and without the insurance fund: the losing position is closed against randomly chosen offsetting positions at its bankruptcy price, which reduces the profit of the accounts on the other side. In dYdX’s worked example, a trader expecting a $500 gain is closed out with $100.

The Hyperliquid pages cited here describe no insurance fund. The liquidator vault is the backstop, and the auto-deleveraging page calls deleveraging the final safeguard on the platform’s solvency. The rule ranks the users on the opposite side by unrealised profit and leverage, and closes the highest-ranked positions at the previous mark price against the underwater account. The documentation states the invariant it protects: a user with no open positions never shares the platform’s losses.

The consequence for a trader on the winning side is easy to miss. A profitable position is not entirely the trader’s to keep open. In the conditions that tend to produce the largest gains, a move fast enough to leave the other side underwater, the venue’s own rules can close it early at a price the trader did not choose.

Total value locked measures something else again. As of 22 November 2026, per DefiLlama, the derivatives category holds $1.6B across the 48 protocols in it with at least $1M each, including Hyperliquid HLP at $148.7M and dYdX V4 at $62.0M, the same figure DefiLlama gives for the whole dYdX chain. Those figures count the value deposited in each protocol under DefiLlama’s rules, not the size of the positions it supports, and what TVL measures sets out those rules.

The position in the United States

In the United States, futures on commodities are regulated by the CFTC. In September 2015 the CFTC held for the first time that bitcoin and other virtual currencies are commodities under the Commodity Exchange Act, which brings a venue offering derivatives on them to US customers within that act’s registration requirements. In November 2023 Binance and its founder agreed, under a proposed consent order, to pay $2.85 billion to resolve CFTC charges that included illegally operating a digital asset derivatives exchange and acting as an unregistered futures commission merchant.

The regulator’s own moves on perpetuals came in sequence, and most of them are recent:

  • 21 April 2025: CFTC staff requested public comment on perpetual contracts, including their risks to market integrity, customer protection and retail trading.
  • 29 May 2026: the Commission approved Kalshi’s BTCPERP contract, a perpetual on the spot price of bitcoin, for listing as a futures contract on Kalshi, a designated contract market. The order’s analysis covers that contract and similarly structured perpetuals on bitcoin or other digital commodities with deep, active and continuous spot markets. The policy statement issued with it says perpetuals on other asset classes should go through case-by-case Commission review. The same day, staff said certain crypto perpetuals listed on a registered firm’s affiliated foreign exchange may be treated as foreign futures.
  • 12 June 2026: a staff no-action letter let exchanges remove the expiry dates from their existing perpetual-style digital commodity futures, which until then had carried them, subject to notice, risk disclosure and a chance for holders to exit. The relief in the letter ran until 30 June 2026.
  • 3 November 2026: CFTC Chairman Michael Selig announced that perpetual futures on individual equities could begin trading on exchanges registered with both the CFTC and the SEC.

The upshot, as of November 2026, is that a perpetual on bitcoin, or on another digital commodity with deep, active and continuous spot trading, can be listed in the United States as a futures contract by a designated contract market, under the CFTC’s framework for futures; perpetuals on other assets go through case-by-case review. The mechanism inside it is the one described above. This describes what the regulator has published; it is not legal advice, and other countries’ rules are separate.

What the contract leaves to the venue

Almost every number in this piece is a parameter: the funding formula and its cap, maximum leverage, maintenance margin, the liquidation penalty, the size and existence of an insurance fund, the order in which winners are deleveraged. On dYdX the documentation says governance can adjust them; on any venue, whoever sets them can change them. What happens when an exchange fails covers the separate question of a venue that cannot pay at all.

The costs also differ from spot trading. Funding is a running charge, or income, on top of the trading fees and the spread that the fees you actually pay sets out for spot. And the depth that matters is the derivative’s own order book, as the exchange liquidity piece says of derivatives on any venue. What Hyperliquid is covers the chain behind one of the two venues used here.