Skip to content

How do crypto arbitrage bots work, and when do they pay?

How crypto arbitrage bots work on perp DEXs: the three trades, the entry rule, break-even math with real fees, and what our tests earned after costs.

By the Prow teamPublished Updated 8 min read

On this page

A crypto arbitrage bot holds a long and an equal short in the same coin on two markets. A long gains when the price rises, and a short gains when it falls, so price moves cancel. The bot keeps the difference in price or in funding, minus fees. It only pays when that difference is larger than the cost of four trades, which is rare. Prow tested this on 25 coins over 2025 and 2026. A test on past prices is a simulation. Trading between venues this way earned about 0.3–1.4% a year after costs.

The examples use perp DEXs: decentralized exchanges for perpetual futures, such as Hyperliquid, Aster and Lighter. Each one is called a venue here.

What is a crypto arbitrage bot?

It is a program that watches one coin on two markets and opens two opposite positions when the numbers allow it. Seven terms cover it.

Pair and leg. The two positions together are a pair. Each position is a leg.

Market-neutral. The legs are the same size in coin terms. If the coin rises 5%, the long gains about what the short loses.

Spread. The difference the bot tries to earn: a price difference or a funding difference between the two markets.

Funding. A perp (perpetual future) has no expiry date. To keep its price near the coin's real price, longs and shorts pay each other a small fee on a schedule. When the rate is positive, longs pay shorts. Hyperliquid settles it every hour, Aster every 8 hours on most markets. See Hyperliquid funding rates explained.

Round trip. Opening and closing both legs. That is four trades, and each one pays a fee.

Taker and maker. A market order fills at once at the current price and pays the higher taker fee. A limit order waits at your price for someone to trade against it and pays the lower maker fee.

Margin, leverage and liquidation. Margin is the money that backs a position. Leverage is the position size divided by the margin. If losses use up the margin, the venue closes the position. That is a liquidation.

What kinds of arbitrage can a bot trade on perp DEXs?

Three. They differ in what they earn and how long the chance lasts.

TradeBuys (long)Sells (short)EarnsHow long the chance lastsMain cost
Price gapThe perp on the cheaper venueThe perp on the dearer venueThe gap closingSecondsFour taker fees
Funding spreadThe perp with lower fundingThe perp with higher fundingThe funding differenceHours to daysFees, and the spread closing early
Spot plus perpThe coin itself, on the spot marketIts perp on the same venuePositive funding on the shortWhile funding stays positiveSpot fees, and funding turning negative

Real price gaps last seconds, so that trade needs market orders. The worked example below counts its fees. The other two have their own guides: funding rate arbitrage between Hyperliquid and Aster and cash and carry on Hyperliquid.

How does an arbitrage bot decide when to enter?

The rule is simple. The income expected while the pair is held must pay for the full round trip, with something left over. Two settings make this concrete.

  • Horizon: how long the bot assumes the spread will last. Costs must be paid back inside it.
  • Entry threshold: the smallest yearly rate, after costs, that makes the pair worth opening.

Take a horizon of 72 hours and a threshold of 8% a year, on a $10,000 leg.

  1. The threshold: $10,000 × 8% × 72 ÷ 8,760 hours in a year = $6.58.
  2. The round trip: $17.00 in fees, counted in the example below.
  3. The spread must pay $6.58 + $17.00 = $23.58 within 72 hours, about $0.33 an hour.
  4. As a yearly rate that is about 29%, held for three full days.

A real bot also subtracts slippage (the price moving while an order fills).

The rule is for saying no, not a forecast. Most of the time nothing clears the bar and the bot waits. Today's differences are on live funding rates.

Worked example: does a 0.10% price gap pay after fees?

BTC trades 0.10% higher on Aster than on Hyperliquid. You short $10,000 on Aster and go long $10,000 on Hyperliquid. If the prices meet, you earn 0.10% of $10,000, which is $10.00.

Base-tier perp fees, checked October 7, 2026: Hyperliquid 0.045% taker and 0.015% maker, Aster 0.04% taker and 0% maker. So a $10,000 market order costs $4.50 on Hyperliquid and $4.00 on Aster.

StepBoth legs at marketLimit order on Aster, market on Hyperliquid
Open: Hyperliquid + Aster$4.50 + $4.00 = $8.50$4.50 + $0.00 = $4.50
Close: the same again$8.50$4.50
Venue fees$17.00$9.00
Gap earned if it closes fully$10.00$10.00
Result before slippage−$7.00+$1.00

With two market orders the round trip costs 0.17% of one leg, so a 0.10% gap loses money.

The limit-order column has two catches. The order can wait while the gap disappears. And a waiting order tends to fill just before the price moves against it. Prow's test charges 0.015% of the order for each such fill until it has measured enough real ones. Two limit fills of $10,000 cost $3.00 at that rate, which turns +$1.00 into −$2.00.

Two more facts shrink the gap itself:

  • Part of it never closes. Hyperliquid prices in USDC and Aster's main perps in USDT. Both are stablecoins, coins meant to stay at one dollar, and they trade slightly apart. In Prow's research, that steady difference averaged about 0.02% on BTC and 0.06% on XRP. Only the part above the usual level can be earned.
  • Prow's own fee applies from Jan 1, 2027. At 0.025% per trade it adds $10.00 to four $10,000 trades. Until then it is 0%. See Fees and perp DEX fees compared.

After removing the steady difference and taker fees, our research found a gap worth trading between these venues at most 2% of the time.

How does the bot open and close both legs?

  1. A limit order waits on one venue.
  2. The moment it fills, the bot opens the opposite leg on the other venue at market. This is the hedge.
  3. It builds the pair in clips. A clip is a small slice of the full size. Each clip is hedged on its own.
  4. If the second leg does not fill in time, the bot closes the first leg again. A small loss costs less than a one-sided position.
  5. It closes both legs together by fixed rules. The gap is back to its usual level, or funding flipped against the pair. A maximum holding time or a loss limit also closes it.

Two limit orders would cost less. But while one waits, the other leg is open alone and exposed to the price.

How much do arbitrage bots earn after costs?

Before building a bot, Prow tested cross-venue trading on 25 coins over 2025 and 2026, with Hyperliquid, Aster and Lighter prices.

How it was tradedResult after costs
One leg as a limit order, the other at market, with an early exit before liquidationAbout 0.3–1.4% a year
Both legs as limit orders (cannot stay hedged)3–7% a year
The bot with default settings, 24 coins, last 180 daysIt lost about 0.9% a year

Three things keep the numbers small. Fees are paid on four trades. Spreads close within hours to days. Limit orders fill at the wrong moment. So a careful bot spends most of its time waiting.

What does an arbitrage bot need from you?

  • Funds already on each venue. USDC on Hyperliquid and USDT on Aster. A bot cannot move money between venues, so each side needs its own margin.
  • A trading key. On Hyperliquid, Aster and Lighter an app trades through a key that can place and cancel orders and cannot withdraw. See agent wallets.
  • A venue that lets a server trade. Lighter charges no fees on a Standard account, but its keys sign only in your browser. See Hyperliquid vs Aster vs Lighter and perp markets.

Prow's Arbitrage bot runs these trades on Hyperliquid and Aster. By default it trades funding spreads only, with a 72-hour horizon and an 8% a year entry threshold. Each leg uses 2x leverage, and a pair is held for 7 days at most. It builds each pair in 4 clips and keeps a stop on each venue. Price gap is off by default. In the app it is under Bots > Create > Arbitrage bot. Read Arbitrage bot first.

Prow's bots use a separate server key that can trade and can never withdraw. See The Prow Bots key and Past results.

Frequently asked questions

Are crypto arbitrage bots profitable?

Sometimes, and by little. In Prow's tests on 25 coins over 2025 and 2026, cross-venue arbitrage earned about 0.3–1.4% a year after costs. The bot with default settings lost about 0.9% a year over the last 180 days of that test.

Is arbitrage trading risk-free?

No. An arbitrage pair is two separate positions. One leg can be liquidated while the other stays open, and fees can cost more than the spread pays.

How much money do you need to run an arbitrage bot?

The smallest order is $10 on Hyperliquid and about $5 on Aster, and you need margin on both venues. Fees are a percentage of the order, so a small account faces the same break-even gap as a large one.

Can an arbitrage bot withdraw my funds?

Not on Hyperliquid, Aster or Lighter when it uses an approved trading key. Such a key can place and cancel orders. Only the wallet that owns the account can sign a withdrawal.

What is the difference between price arbitrage and funding arbitrage?

Price arbitrage buys a coin where it is cheaper and sells where it is dearer, and earns when the two prices meet. Funding arbitrage holds a long and a short on perpetual futures and earns the difference in funding payments while it lasts. Price gaps close in seconds. Funding differences last hours to days.

Sources

Checked October 7, 2026: