What Is a Perp DEX? How On-Chain Perpetuals Work
A perp DEX is a decentralized exchange where you trade perpetual futures from your own wallet. Margin sits in smart contracts instead of with a company, and trades settle on a blockchain. You get leverage without handing custody to an exchange, but you take on smart-contract risk and liquidation risk.
“Perp” is short for perpetual future, a leveraged contract with no expiry date. A perp DEX offers those contracts on a blockchain. If you haven’t met the product before, start with how perpetual futures work.
Perp DEX vs centralized perp exchange
| Perp DEX | Centralized exchange (CEX) | |
|---|---|---|
| Who holds your funds | Smart contracts you connect your wallet to | The exchange company |
| Account | A wallet address, often with no sign-up form | Email account, usually with identity checks |
| Settlement | On a blockchain, sometimes a chain built for trading | In the exchange’s private database |
| Visibility | Positions and liquidations are often public on-chain | Private |
| Main risks | Smart-contract bugs, oracle errors, fake front-ends, wallet mistakes | Exchange hack, insolvency, frozen withdrawals |
| Support if you err | Limited; blockchain transactions can’t be reversed | A support team, though no guarantee |
For the wider comparison, see DEX vs CEX. If this topic is new to you, how to use dYdX explains the deposit, trading and withdrawal steps on that perpetuals exchange. Our page on what Sei is goes into a layer 1 built with trading in mind.
How a perp DEX works
- Connect a wallet. You use a self-custody wallet, or in some cases an email-based wallet the app creates. The app asks you to sign messages to prove you control the address.
- Deposit margin. You send a stablecoin, usually USDC, from a supported chain. Depositing and withdrawing can involve network fees and bridges.
- Trade against an order book or a liquidity pool. Some perp DEXs run an order book on a fast chain, matching buyers and sellers like a traditional exchange. Others price trades against a shared pool of liquidity and an oracle, a service that feeds in the real price.
- Pay and receive funding. Funding payments keep the perp price close to the underlying price.
- Get liquidated or close. If your margin can no longer cover your losses, a liquidation process closes the position.
Hyperliquid is one example of a perp DEX; our Hyperliquid guide covers how it is set up and what it charges. For more background, see whether GMX is safe, which covers its audits, risks and what is not protected. If this topic is new to you, what Aster is explains the Aster DEX and its ASTER token.
A worked example: a long position and funding
The numbers are round and hypothetical, and fees on a real platform will differ. Suppose you deposit 1,000 USDC and open a long on a coin priced at 100 with 5x leverage.
- Position size: 1,000 × 5 = 5,000 USDC, or 50 units of the coin.
- The price rises 4% to 104. The position gains 50 × 4 = 200 USDC, which is 20% of your margin.
- Suppose the taker fee is 0.05% each way. Opening costs 5,000 × 0.05% = 2.50 USDC and closing at 5,200 costs 5,200 × 0.05% = 2.60 USDC.
- Suppose funding charged you 0.01% of the position over the hold, which is 0.50 USDC.
- Net result: 200 − 2.50 − 2.60 − 0.50 = 194.40 USDC.
- Had the price fallen 4% instead, you would have lost about 200 USDC plus the same costs, so the 1,000 margin would drop to around 795 USDC.
- A fall of roughly 20% would wipe out the margin. A liquidation usually happens a little before that, because the platform keeps a buffer.
Leverage did not change the direction, only the size of the effect.
What can go wrong on a first trade
| Situation | What to do |
|---|---|
| Your deposit does not appear | Check the chain and token you sent. A wrong chain can lose funds, so send a small test first. |
| The app shows a different liquidation price than you expected | Read the platform’s formula. It depends on margin mode, fees and funding. |
| Your order fills far from the quote | A thin market, or a large order. Use a limit order and a smaller size. |
| You cannot close a position | The chain may be congested or the app down. Do not use high leverage on positions you cannot watch. |
| You are asked to sign an unusual message | Reject it and check the site address before trying again. |
What to look for when comparing perp DEXs
There is no honest single answer to “best perp DEX”, because the right one depends on your country, the assets you want and your risk tolerance. Compare these points on each platform’s official documentation:
- Fees. Maker and taker fees, any extra interface fee, and how funding is calculated.
- Markets and leverage limits. Which assets are listed, and the maximum leverage on each.
- Where your money sits. The chain, the bridge you use to deposit, and whether withdrawals have limits or delays.
- Liquidation rules. How liquidation prices are calculated and what happens in extreme moves.
- Audits and incident history. Check whether audits are published and how the team handled past problems. An audit lowers the risk but does not remove it.
- Availability. Terms often restrict some countries. Read them before you deposit.
Risks specific to perp DEXs
- Leverage and liquidation. Leverage multiplies gains and losses, and a small move can liquidate you at high leverage. Liquidated margin is lost. Only trade with money you can afford to lose.
- Smart-contract risk. Bugs or exploits can drain funds. Newer protocols have less history.
- Oracle and market manipulation. Thinly traded assets can be pushed around, and a wrong price feed can trigger unfair liquidations.
- Slippage. Large orders can fill away from the price you saw. See what slippage is.
- Fake front-ends and phishing. Copycat sites, fake apps and sponsored ads imitate popular platforms. Use a bookmarked official address, check the URL before connecting, and never type your seed phrase into a website.
- Token approvals. Some apps ask you to approve a contract to spend your tokens. Approve only what you need and revoke old approvals through a token-approval checker or your wallet.
Common questions
Do I need to hand over identity documents to use a perp DEX?
Often the app itself doesn’t ask for documents, but the platform’s terms can still restrict certain countries, and the on-ramps you use to get funds in may require identity checks. Read the terms of the platform you plan to use.
What is funding on a perp DEX?
Funding is a periodic payment between long and short traders that keeps the perpetual’s price near the underlying price. Depending on the market, you may pay it or receive it, and the rate changes.
Can I lose more than my margin?
On most platforms the loss is meant to be limited to the margin you posted, because a liquidation closes the position first. Fast markets can move past the liquidation price, so costs and shortfalls can still arise. Read the platform’s rules.
Is a perp DEX safer than a centralized exchange?
It is different, not automatically safer. You avoid trusting a company with custody, but you rely on code and your own wallet security.
Sources
- hyperliquid.gitbook.io supports: Documentation of an on-chain perpetuals exchange: onboarding, margin and trading
- ethereum.org supports: Overview of decentralized finance and on-chain trading