Cross-Exchange Arbitrage
Spot-perp arbitrage, cross-exchange spread trading, triangular arbitrage, funding rate arb: execution mechanics, latency, fees, and capital requirements.
From Thrive on YouTube
Watch the matching Thrive video
Isolated vs Cross Margin: Which Should You Use and When
Part of Start Here: Crypto Futures Basics. Education only. Not financial advice.
Arbitrage Fundamentals
Arbitrage in crypto exploits price discrepancies between venues. Unlike traditional markets where arbitrage opportunities are sub-millisecond and require co-located hardware, crypto arbitrage windows can last seconds to minutes due to fragmented liquidity, slow block confirmations, and structural inefficiencies in how exchanges process withdrawals. The total addressable arb market in crypto is estimated at $50-150M daily across all forms. But accessible profit after fees, slippage, and capital costs is a fraction of that.
The core principle is the law of one price: the same asset should cost the same everywhere. When it does not, an arbitrageur buys on the cheap exchange and sells on the expensive one. In practice, price discrepancies persist because of withdrawal delays, deposit confirmation times, exchange-specific liquidity, regional demand differences, and the capital required to pre-fund multiple exchanges.
Cross-Exchange Spot Arbitrage
The simplest form: BTC/USDT trades at $65,000 on Binance and $65,150 on Coinbase. Buy on Binance, sell on Coinbase, pocket $150 minus fees. The catch is execution. You need pre-funded balances on both exchanges. If you buy on Binance and then try to withdraw to Coinbase to sell, the price will have converged by the time the transfer settles. The standard approach is to maintain capital on both exchanges and periodically rebalance inventory via transfers during non-volatile periods.
Fee analysis is critical. Binance maker fee is 0.02% with BNB discount. Coinbase Advanced maker fee is 0.04%. On a $65,000 BTC trade, total fees are roughly $39. The $150 spread becomes $111 profit. But slippage on the market order side (the exchange where you are lifting the offer) typically adds 0.02-0.05% depending on size and liquidity. At 0.03% slippage on $65,000, that is another $19.50. Net profit: ~$91. On $65,000 of capital deployed, that is 0.14% per arb. Viable only at scale with high frequency.
1import ccxt2import asyncio3import time45EXCHANGES = {6 'binance': ccxt.binance({'enableRateLimit': True}),7 'coinbase': ccxt.coinbase({'enableRateLimit': True}),8 'kraken': ccxt.kraken({'enableRateLimit': True}),9 'okx': ccxt.okx({'enableRateLimit': True}),10}1112async def fetch_prices(symbol='BTC/USDT'):13 prices = {}14 for name, exchange in EXCHANGES.items():15 try:16 ticker = exchange.fetch_ticker(symbol)17 prices[name] = {18 'bid': ticker['bid'],19 'ask': ticker['ask'],20 'spread_pct': (ticker['ask'] - ticker['bid']) / ticker['bid'] * 10021 }22 except Exception as e:23 print(f"{name} error: {e}")24 return prices2526def find_arb_opportunities(prices, min_spread_bps=10):27 """Find profitable cross-exchange arb opportunities."""28 opportunities = []29 exchanges = list(prices.keys())30 for i, buy_ex in enumerate(exchanges):31 for sell_ex in exchanges[i+1:]:32 buy_ask = prices[buy_ex]['ask']33 sell_bid = prices[sell_ex]['bid']34 spread_bps = (sell_bid - buy_ask) / buy_ask * 1000035 if spread_bps > min_spread_bps:36 opportunities.append({37 'buy_on': buy_ex, 'sell_on': sell_ex,38 'buy_price': buy_ask, 'sell_price': sell_bid,39 'spread_bps': round(spread_bps, 1),40 'est_profit_per_btc': round(sell_bid - buy_ask, 2)41 })42 # Check reverse direction43 spread_bps_rev = (prices[buy_ex]['bid'] - prices[sell_ex]['ask']) / prices[sell_ex]['ask'] * 1000044 if spread_bps_rev > min_spread_bps:45 opportunities.append({46 'buy_on': sell_ex, 'sell_on': buy_ex,47 'buy_price': prices[sell_ex]['ask'],48 'sell_price': prices[buy_ex]['bid'],49 'spread_bps': round(spread_bps_rev, 1),50 'est_profit_per_btc': round(prices[buy_ex]['bid'] - prices[sell_ex]['ask'], 2)51 })52 return sorted(opportunities, key=lambda x: x['spread_bps'], reverse=True)5354# Run continuous monitoring55while True:56 prices = asyncio.run(fetch_prices())57 opps = find_arb_opportunities(prices)58 if opps:59 for opp in opps:60 print(f"BUY {opp['buy_on']} @ {opp['buy_price']:,.0f} | "61 f"SELL {opp['sell_on']} @ {opp['sell_price']:,.0f} | "62 f"Spread: {opp['spread_bps']}bps | "63 f"Est profit: ${opp['est_profit_per_btc']}")64 time.sleep(1)Spot-Perp Arbitrage (Basis Trade)
Perpetual futures often trade at a premium or discount to spot. During bull markets, perps trade at a premium because leveraged longs pay to maintain positions. The funding rate mechanism forces convergence, but the premium can persist for weeks. The basis trade is: buy spot, short perps, collect funding. This is the most capital-efficient and lowest-risk arb in crypto, earning 15-40% APY during bull markets with near-zero directional risk.
Mechanics: buy 1 BTC spot at $65,000 on Binance. Short 1 BTC perpetual on Binance at $65,100. You are delta-neutral: spot and perp offset. Every 8 hours, if funding is positive (longs pay shorts), you collect funding. At 0.03% per 8 hours (common in bull markets), that is 0.09%/day or ~33% APY on the combined capital. Risks include negative funding (you pay), exchange insolvency, and liquidation if your perp margin is insufficient during a spike. Size the perp position with enough margin to survive a 30-50% adverse move without liquidation.
Triangular Arbitrage
Triangular arb exploits mispricings between three currency pairs on the same exchange. If BTC/USDT, ETH/BTC, and ETH/USDT are inconsistent, you can cycle through all three and end up with more USDT than you started. The math: start with 1 USDT, buy BTC, use BTC to buy ETH, sell ETH for USDT. If the product of the three exchange rates (after fees) exceeds 1.0, you have an arb. In practice, triangular arb on major pairs yields 0.5-2 bps per cycle: viable only with low maker fees and high execution speed. It is more profitable on smaller exchanges with wider spreads but less liquid books.
1def detect_triangular_arb(exchange, base='USDT', pairs=None):2 """Detect triangular arbitrage on a single exchange."""3 tickers = exchange.fetch_tickers()4 5 triangles = [6 ('BTC/USDT', 'ETH/BTC', 'ETH/USDT'),7 ('BTC/USDT', 'SOL/BTC', 'SOL/USDT'),8 ('ETH/USDT', 'SOL/ETH', 'SOL/USDT'),9 ]10 11 results = []12 for a, b, c in triangles:13 try:14 ask_a = tickers[a]['ask'] # buy first asset15 bid_b = tickers[b]['bid'] # sell for second asset16 bid_c = tickers[c]['bid'] # sell second asset for base17 18 # Forward path: USDT -> A -> B -> USDT19 qty_a = 1.0 / ask_a # buy asset A20 qty_b = qty_a * bid_b # convert A to B21 final = qty_b * bid_c # convert B to USDT22 23 fee_factor = (1 - 0.001) ** 3 # 0.1% fee per leg24 net = final * fee_factor25 26 if net > 1.0:27 profit_bps = (net - 1.0) * 1000028 results.append({29 'path': f"{a} -> {b} -> {c}",30 'gross_ratio': round(final, 6),31 'net_ratio': round(net, 6),32 'profit_bps': round(profit_bps, 1)33 })34 except (KeyError, TypeError):35 continue36 37 return sorted(results, key=lambda x: x['profit_bps'], reverse=True)Funding Rate Arbitrage
Funding rates vary across exchanges. Binance BTC perp might have a funding rate of +0.01% while Bybit is at +0.05%. You can short on Bybit (collecting 0.05%) and long on Binance (paying 0.01%) for a net 0.04% per 8 hours. This is a delta-neutral cross-exchange play that requires capital on both venues. The primary risk is execution timing: funding rates are snapshots. If the rate changes between when you open and when funding settles, you might pay more or receive less than expected. Monitor funding rate trends, not just spot values. A rate that has been declining for 6 hours might flip negative by settlement.
Execution Mechanics
API roundtrip times range from 5ms (co-located) to 200ms+ (residential). In spot-spot arb, 100ms of latency can erase a 5 bps spread. Use WebSocket feeds for price discovery and REST for order placement only when an opportunity is confirmed.
Maker/taker fee differential is critical. Maker orders (limit orders that add liquidity) are 2-5x cheaper. Place limit orders on the slow side and market orders on the fast side. VIP tiers from volume rebates can reduce fees by 50-80%.
Use order book depth data to estimate slippage before executing. A $100K market order on a pair with $500K within 10 bps of mid-price will experience ~2 bps of slippage. On a pair with $50K depth, expect 20+ bps.
Capital locked on multiple exchanges earns zero yield when idle. Track your effective capital utilization rate: active arb capital / total deployed capital. Below 30% utilization, the opportunity cost exceeds arb profits for most strategies.
Cross-exchange arb creates inventory imbalances. You accumulate BTC on the sell exchange and USDT on the buy exchange. Periodic rebalancing via withdrawals incurs blockchain fees and delay risk. Batch rebalances during low-vol UTC mornings.
Start with basis trades
1.In a spot-perp basis trade during a bull market, where does the yield come from?
2.Why does cross-exchange spot arbitrage require pre-funded balances on multiple exchanges?
3.A triangular arb path BTC/USDT → ETH/BTC → ETH/USDT returns a gross ratio of 1.0008 before fees. With 0.1% fee per leg (3 legs), is this profitable?
Put this lesson to work
Free on Thrive, no account needed.