Bitget App
Trade smarter
Buy cryptoMarketsTradeFuturesEarnWeb3SquareMore
Trade
Spot
Buy and sell crypto with ease
Margin
Amplify your capital and maximize fund efficiency
Onchain
Going Onchain, without going Onchain!
Convert & block trade
Convert crypto with one click and zero fees
Explore
Launchhub
Gain the edge early and start winning
Copy
Copy elite trader with one click
Bots
Simple, fast, and reliable AI trading bot
Trade
USDT-M Futures
Futures settled in USDT
USDC-M Futures
Futures settled in USDC
Coin-M Futures
Futures settled in cryptocurrencies
Explore
Futures guide
A beginner-to-advanced journey in futures trading
Futures promotions
Generous rewards await
Overview
A variety of products to grow your assets
Simple Earn
Deposit and withdraw anytime to earn flexible returns with zero risk
On-chain Earn
Earn profits daily without risking principal
Structured Earn
Robust financial innovation to navigate market swings
VIP and Wealth Management
Premium services for smart wealth management
Loans
Flexible borrowing with high fund security
Parsing the HyperEVM Arbitrage Bot: How to Seize a 2-Second Opportunity to Earn $5 Million?

Parsing the HyperEVM Arbitrage Bot: How to Seize a 2-Second Opportunity to Earn $5 Million?

BlockBeatsBlockBeats2025/10/21 08:30
By:BlockBeats

From discovering the 2-second price difference exploit in HyperEVM block, to setting up an arbitrage bot to outperform competitors, to introducing perpetual contracts to achieve a $5 million profit, we completed this crypto arbitrage real-world battle in 8 months.

Original Article Title: How We Made $5M Running the #1 Arbitrage Bot on HyperEVM
Original Article Author: CBB
Original Article Translation: Saoirse, Foresight News


It is now March 2025, and the cryptocurrency industry seems to be in turmoil, heavily impacted by tariffs. We have been searching for the next prime opportunity — at that time, 40% of the HYPE tokens were still awaiting distribution to the community, which we saw as a potential breakthrough. Back in February, we had tested some liquidity strategies on the UNIT asset, but it was all small-scale experimentation that did not yet take off.


Upon the launch of HyperEVM, several decentralized exchanges (DEXs) were introduced as part of the ecosystem. My brother suggested, "Why don't we try arbitraging between HyperEVM and Hyperliquid? Even if it requires some upfront investment, we might be able to participate in Hyperliquid's third-quarter event." We promptly began our attempts and indeed found arbitrage opportunities, but we were uncertain if we had a competitive edge.


Why Are There Arbitrage Opportunities on HyperEVM?


HyperEVM has a 2-second block generation interval, meaning the price of the HYPE token updates only once every 2 seconds. Within these 2 seconds, the price of HYPE may have fluctuated, causing HYPE on HyperEVM to often be either "underpriced" or "overpriced" compared to the Hyperliquid platform.


Initial Attempts and Results


We deployed the first version of our arbitrage bot, with basic functionality: whenever there was a price discrepancy between the automated market maker (AMM) DEX liquidity pool on HyperEVM and the Hyperliquid spot market, it would initiate a trade on HyperEVM and hedge on Hyperliquid.


For example:


- If HYPE's price rises on Hyperliquid, it would be undervalued on HyperEVM;


- Arbitrage process: Buy the "underpriced" HYPE with USDT0 on HyperEVM → Sell HYPE to convert to USDC → Swap USDC back to USDT0 on Hyperliquid.


In the first few days, our daily trading volume on Hyperliquid was around $200,000 to $300,000. Not only did we avoid losses, but we also managed to profit a few hundred dollars. Initially, the arbitrage threshold we set was: after deducting the transaction fees of the AMM DEX and Hyperliquid, a trade would only be executed if the profit exceeded 0.15%.


Two weeks later, as the profit continued to grow, we saw greater potential and also identified two competitors who were operating identically to us—albeit on a smaller scale. We were determined to eliminate them.


In April 2025, Hyperliquid introduced the HYPE staking rebate mechanism (staking tokens could offset transaction fees), which was a great opportunity for us. Our fund size already exceeded that of our competitors, so we staked 100,000 HYPE tokens, received a 30% transaction fee rebate, and reduced the arbitrage profit threshold from 0.15% to 0.05%.


Our goal was clear: to force our competitors to exit by maximizing pressure and monopolizing the market. At the same time, we planned to increase the trading volume to over $500 million within two weeks to upgrade our fee tier on Hyperliquid.


Ultimately, the trading volume and profit soared simultaneously. When the trading volume exceeded $500 million, our competitors were completely at a loss. I still remember that day: my brother and I were flying from Paris to Dubai, watching the bots "printing money" crazily, making a profit of $120,000 within 24 hours, while both competitors shut down their bots.


Nevertheless, some competitors did not give up. They were enduring higher fees, forcing us to compress the arbitrage profit margin to about 0.04% (essentially equal to the difference in fees between us and them). Despite this, our trading volume remained strong, and daily profits stabilized between $20,000 and $50,000.


Issues and Solutions in Scaling Up


As our business expanded, we encountered new limitations: the Gas fee limit per block on HyperEVM was 2 million, while a single arbitrage transaction consumed about 130,000 Gas. This meant that each block could only handle 7-8 arbitrage trades at most. Especially as more liquidity pools and DEXs went live on HyperEVM, this limitation became more pronounced, and there were even instances of transaction congestion—we had to quickly address this to avoid transaction queues and order book imbalances.


To tackle this, we took four measures:


· Enabled over 100 wallets, each initiating arbitrage transactions separately to avoid queueing caused by a single wallet executing too many transactions;


· Limit each block to a maximum of 8 arbitrage transactions;


· Gas Price Control: When the Gas price on HyperEVM surges, increase the required return on investment (ROI) for arbitrage to avoid transactions getting stuck due to high Gas fees;


· Transaction Rate Limit: If the number of transactions sent in the past 12 seconds exceeds a set amount (x transactions), then increase the profit requirement for new transactions.


Optimization Upgrade Era: From "Taker" to "Liquidity Provider"


As our profits continued to grow and our trading volume reached 5-10 times that of our competitors, we became obsessed with further optimization—after all, in the cryptocurrency industry, what was profitable today could be overtaken by new players tomorrow.


Transition to Liquidity Provider: Seizing More Opportunities


In June 2025, my brother proposed an idea that had been brewing for weeks: to conduct arbitrage on Hyperliquid as a "Liquidity Provider" instead of a "Taker" (Note: a Liquidity Provider offers liquidity, placing orders and awaiting execution; a Taker directly matches against existing orders). This transition had two major advantages:


· It could capture more arbitrage opportunities brought about by rapid price fluctuations in HYPE;


· Each transaction could save 0.0245% in fees, directly increasing profits.


However, the transition also came with risks: as a Liquidity Provider, we needed to first have our orders executed on Hyperliquid but couldn't guarantee completing the reverse transaction on HyperEVM (there might be opponents faster than us), leading to order book imbalances and potential losses.


During initial testing, we experienced imbalances of up to ±10k HYPE each time—we sometimes sent 100 transactions within 20 seconds, but without any data analysis tools, we couldn't find the reason for the imbalance, making the situation a mess.


To address this issue, we introduced a series of concepts and translated them into code and parameters:


· Profit Range: Clearly defining when to create an order, when to hold an order, and when to cancel and re-place an order;


· Liquidity Provider Trading Range: Specifying the AMM liquidity pools willing to participate in liquidity provision (e.g., the HYPE/USDT0 pool on HyperSwap with a 0.05% fee rate, the HYPE/UBTC pool on PRJX with a 0.3% fee rate);


· Single Pool Trading Size and Order Limit: Set a maximum trading size and order limit for each AMM liquidity pool.


The parameters for the LP trading are as follows:


Parsing the HyperEVM Arbitrage Bot: How to Seize a 2-Second Opportunity to Earn $5 Million? image 0


After several days of fine-tuning, we have finally resolved the imbalance issue. Even if imbalance occurs occasionally, it can be quickly adjusted through Time-Weighted Average Price (TWAP) to control risk. This transformation can be described as a "game-changer" — while competitors are still in the "order eater" mode, our trading volume has reached 20 times theirs.


Skip the USDT0/USDC Exchange to Reduce Costs


Another major challenge is related to stablecoins: the primary stablecoin on Hyperliquid is USDC, while on HyperEVM it is USDT0; the HYPE/USDT0 liquidity pool on HyperEVM has the highest trading volume and most arbitrage opportunities. However, due to different cross-chain stablecoins, we need to execute 2 additional trades on Hyperliquid to complete asset hedging, for example, when the HYPE price surges:


1. LP order execution → Sell HYPE for USDC with zero fees;


2. Buy HYPE with USDT0 on HyperEVM;


3. Sell USDC for USDT0 on Hyperliquid as an order eater (0.0245% fee).


The drawback of the third step is evident: having to pay the order eating fee (reducing profits, weakening competitiveness), and the USDT0/USDC trading market on Hyperliquid is not mature enough (with spreads and pricing deviations).


Therefore, we have designed new parameters and logic to skip this step as much as possible:


· USDC Balance Threshold: Only skip the USDT0→USDC exchange when the USDC balance exceeds 1.2 million;


· USDT0 Balance Threshold: Only skip the USDC→USDT0 exchange when the USDT0 balance exceeds 300,000;


· Real-Time Price Data Source: Call the Cowswap API every minute to obtain the real-time price of USDT0/USDC, instead of relying on Hyperliquid's order book price.


Introducing Perpetual Contracts to Diversify Revenue Streams


First and foremost, we'd like to clarify that throughout our entire cryptocurrency investment journey, we have never utilized leverage or perpetual contracts (except for an unsuccessful attempt on Bitmex in 2018), and we have limited knowledge of how they operate.


However, we observed that the trading volume of HYPE perpetual contracts is significantly higher than spot trading, with lower fees as well (spot trading 0.0245% vs perpetual contracts 0.019%). Therefore, we decided to explore combining our arbitrage strategy with perpetual contracts—back then, no competitors were using this approach, so we didn't need to compete with them in the same order book liquidity.


More importantly, during the testing phase, we discovered that leveraging perpetual contracts not only allowed us to earn arbitrage profits but also enabled us to profit from the "funding rate." When the HYPE perpetual contract exhibited a premium or discount relative to the spot price, we could capture additional arbitrage opportunities—areas where our competitors had not ventured into.


For this purpose, we designed new system parameters:


· Position Limit: Set the maximum long/short position size for HYPE perpetual contracts to avoid liquidation or depleting the USDC/HYPE balance;


· Premium/Discount Monitoring: Real-time tracking of the premium or discount of perpetual contracts relative to the spot price;


· Premium/Discount Cap: If the premium is too high, cease opening long positions and resort to spot trading instead;


· Progressive ROI: The larger the position size, the higher the required arbitrage profit, to prevent quick entry into risky positions;


· ROI Calculation Formula: Comprehensive calculation combining the perpetual contract's premium/discount and the position size.


Below is an example interface/parameter setting for configuring a short position in the HYPE token as a maker:


Parsing the HyperEVM Arbitrage Bot: How to Seize a 2-Second Opportunity to Earn $5 Million? image 1


Introducing perpetual contracts was one of the key upgrades—we earned approximately $600,000 solely through the funding rate and captured more arbitrage opportunities leveraging the premium/discount.


Brotherly Partnership: Collaborative Mode and Complementary Advantages


People often inquire about how we divide tasks and collaborate. The external perception seems to be that I am the "meme creator," only engaging in casual cryptocurrency social media discussions (CT), while my brother is merely a "tech geek," responsible for coding. However, the reality is much more intricate—our collaboration model is akin to what we previously experienced during our involvement in Blur mining.


During the operation of the arbitrage bot, we encounter new issues every day that require timely resolution. We discuss optimization solutions continuously, and all decisions must be consensus-driven before execution. My brother is responsible for the code but also develops tools that allow me to adjust parameters autonomously; I have no coding knowledge whatsoever, and my brother is not good at configuring the bot parameters—we complement each other perfectly.


Interestingly, our work styles are completely opposite: my brother likes to push updates and try new features (which I find somewhat excessive); whereas I am very conservative (he thinks overly so) and am only interested in maintaining the current version if the bot is consistently profitable.


Our daily conversations often go like this:

· Me (in an impatient tone): "Something's off with the bot... Did you change something?"


· Brother: "Nope... Just made some insignificant tweaks at most."


Additionally, as a two-person team without formal company processes, after iterating the bot over 250 versions, we sometimes feel that the more we build, the harder it becomes to fully comprehend and control our creation. It's challenging to anticipate the ripple effects of each update.


Summary


Over the past 8 months, we have dedicated ourselves to building and optimizing this arbitrage bot—especially in June 2025 when the crypto market maker, Wintermute, entered with significant liquidity and a team, intensifying the competition.


I still remember those 5 days in July: my brother and I had planned to relax in Istanbul and Bodrum (Turkish cities) but ended up focusing on optimizing the bot the entire time.


Ultimately, our bot held the top position in the HyperEVM arbitrage field for 8 consecutive months. By October, as the market share gradually declined, we felt it was time to exit.


The core data from this experience:


· Total Profit: $5 million;


· Total Trading Volume on Hyperliquid: $12.5 billion;


· Gas Fees Paid on HyperEVM: $1.2 million (20% of the total Gas fees since HyperEVM's launch);


· Total Time Invested: Over 2000 hours;


· 5% of the total transaction volume in the UNIT ecosystem.


Looking forward to the arrival of Hyperliquid Season 3 and UNIT Season 1.


0

Disclaimer: The content of this article solely reflects the author's opinion and does not represent the platform in any capacity. This article is not intended to serve as a reference for making investment decisions.

PoolX: Earn new token airdrops
Lock your assets and earn 10%+ APR
Lock now!

You may also like

Nexchain AI Crypto Presale Advances Blockchain Scalability with DAG and AI Events Ahead of Testnet 2.0 Rollout

Nexchain AI crypto presale nears full Stage 28 target as Testnet 2.0 launch in November boosts demand for scalable blockchain tech.Nexchain’s Blockchain Features Stand Out as Presale Token Demand RisesCrypto Presale Phases Accelerate as Bonus Campaigns Drive GrowthAirdrop Campaign and Long-Term Strategy Continue to Attract Users

Coinomedia2025/10/21 19:00
Nexchain AI Crypto Presale Advances Blockchain Scalability with DAG and AI Events Ahead of Testnet 2.0 Rollout

Solana’s $530M Treasury & XRP’s ETF Dreams Can’t Match BlockDAG’s $430M Presale Momentum & Limited-Time $0.0015 Entry

Discover how BlockDAG’s $0.0015 TGE code, $425M presale, and 3.5M miners outshine Solana’s $530M treasury boost and XRP’s ETF rally as 2025’s next crypto surge builds.Solana’s $530M Treasury Move Sparks ConfidenceXRP’s ETF Buzz Pushes It Toward a $12 TargetBlockDAG’s $0.0015 TGE Code Creates Unstoppable Market FrenzyLooking Forward

Coinomedia2025/10/21 19:00
Solana’s $530M Treasury & XRP’s ETF Dreams Can’t Match BlockDAG’s $430M Presale Momentum & Limited-Time $0.0015 Entry