📱

Get Our Mobile App

Take your business learning on the go!

Download on the App StoreGet it on Google Play

How to Create Passive Income MEV Bot on Ethereum Full Tutorial

MysteryCake11:00

Transcription

Hey everyone, my name is Jane, and I am a Web 3 developer.

Over the past year, I've been trying to create a bot that could generate passive income for me. But spoiler alert: it didn't go as planned. My smart contract just didn't deliver the results I hoped for, and in fact, I ended up losing money.

Then, I turned to artificial intelligence for help, and things changed. CH MPD has become my go-to tool for simplifying crypto projects, all with the goal of building real passive income.

But before we get started, a quick reminder: the crypto world can be full of scammers, so stay safe. Don't send money to unknown wallets or deal with shady exchanges. Protect yourself and your funds.

All right, so let's jump right in and get started on this journey.

The basis of the bot is concepts of arbitrage, pools, and sandwich transactions. Notably, it leverages popular decentralized platforms like Uniswap and other DEXs.

Now, put simply, the bot operates on the principle of sandwich transactions. It analyzes a pool, essentially a waiting room for transactions that have been initiated but not yet processed. This allows us to execute transactions by specifying a gas price higher than the initiated one, resulting in a profitable price slip in the transactions.

If this concept seems too difficult, rest assured it is straightforward.

Now, I've been using this bot for a few weeks, and it's important to clarify that no coding experience is required whatsoever. CH has made this aspect hassle-free.

So let's dive into the details and get started.

We'll begin by ensuring that you have the MetaMask extension installed. You can use any wallet of your choice; the main thing is that it is installed in your browser. It may be Coinbase Wallet, Trust Wallet, etc. All steps are exactly the same but with different wallet interfaces.

First, let's open the bot's source code from the video description and insert it into the clipboard. Then go to the Remix IDE website. All the links are available in the description.

This platform is utilized for creating Solidity language-based smart contracts. Avoid scam Remix URLs and use only the original Remix IDE website: remix.ethereum.org. It will not let you proceed with suspicious transactions.

Now, we are creating a new file, and feel free to name it according to your preference. For instance, let's call it "bot."

Paste the open-source bot code from the video description. Carefully read the pasted code alert and remember to verify the code yourself. Go ahead and scroll up to read the quick user guide.

Now, it's important to know that for the bot to function optimally, it requires a minimum deposit of 0.5 ETH or more. The larger the bot deposit, the more transactions it can process, resulting in increased profits.

Confirm that your wallet contains more than 0.5 ETH and is connected to the Ethereum mainnet. Then, move to the Solidity compiler tab to compile the bot. Enable optimization to reduce gas usage, enable auto-compile, and then click on "Compile Bot."

Proceed to the "Deploy and Run Transactions" section. Within the environment tab, opt for "Injected Provider - MetaMask" or your wallet. Confirm the wallet connection upon successful link and proceed to click on "Deploy."

Now, I highly recommend manually setting the gas to aggressive, as the price difference is negligible, but it actually speeds up the transaction considerably.

All right, so now wait for the deployment of our bot. Check the terminal for the deployed message, and here we have the message. Click on it and then copy the transaction hash.

Next, we'll verify on Etherscan to confirm that your bot has been successfully deployed, with the transaction status displayed as successful. This indicates that the bot is deployed.

Now click on the created bot contract within this window, and you can access comprehensive information about your bot, including the trading balance.

All right, so now I'm going to return to Remix, and you can explore the main menu of the bot.

Allow me to provide a brief overview of the functions of each button:

- "Set Trade Balance" sets the bot's trade deposit in ETH.

- "Set Trade Balance Percent" sets the bot's trade deposit as a percentage of the deposit in your wallet.

- "Start Native" starts the bot.

- "Stop" stops the work of the bot.

- "Withdraw" allows you to withdraw your profit from your bot contracts to your wallet.

- "Key" is your personal API key for working with the bot, and please don't share it with anyone.

Okay, so now I'm going to select the "Key" button and copy the provided key. I'm going to scroll up, paste it into the value tab, and then I'm just going to specify the deposit size for the bot. For example, I'll set it to 1 ETH.

Finally, I'll click "Start Native."

So, observing this situation, the bot thoroughly analyzes our entire wallet, so ensure that you're connected to the Ethereum mainnet and confirm.

Let's wait for my transaction confirmation. Yes, it's confirmed!

Then you're going to Etherscan, and let's check my smart contract balance. Refresh the page. It's evident that the bot has received precisely 1 ETH for trading, while the remaining amount is retained in my wallet.

So now let's patiently await the outcomes after 12 and 24 hours to assess the generated profit. I'll stop the screen record and come back after 12 hours.

All right, so after 12 hours, let's review the results by refreshing the page. I've earned 0.48 ETH passively, and that's equivalent to around $1,700 at the current exchange rate. That's quite an impressive outcome, I would say.

So I'm going to post the screen record again and come back after another 12 hours.

Now, wait another 12 hours, and upon reaching the 24-hour mark, let's assess the bot's performance. Refresh the page, and you'll notice that I've earned nearly 1.2 ETH in this period. So that's approximately $3,800 at the current exchange rate.

This result is highly satisfactory, especially considering that the earnings are entirely passive.

So returning to Remix, let's proceed to withdraw the funds back to the wallet. Begin by pressing "Stop," adjust the gas to aggressive liquidity, and confirm the transaction.

Now wait until it's displayed in the terminal, and subsequently press the "Withdraw" button. Change the gas to aggressive again and confirm the transaction.

Then wait for it to appear in the terminal.

So waiting... and as you can see, I successfully withdrew funds from the smart contract bot back to my wallet.

So let's check my wallet. Nice, money's in my wallet!

Now let's verify the smart contract balance. Currently, the bot has zero ETH balance, so don't forget to refresh the page for updated information.

Attention! Now my bot is absolutely free to show how perfect it is and how much money you can make. However, after one month, I'm going to close the free version of the bot, so API keys will not be active.

Your bot will not be able to deploy the contract, and the preliminary cost will be $2,500 per week. Until this time, everyone is welcome to try it and get some really nice profit.

All right, next information is very important. If you have some errors after your contract deploy, let me show you how to fix it.

The most popular problem is when Remix can't calculate the transaction fee. This is due to the fact that after you wait more than 10 minutes, Remix just loses connection with the bot code.

To fix this, we need to reconnect to the contract or create a new one. We should follow all steps faster or reconnect to the contract first.

Update the page, click on the bot file—in my case, "bot.sol"—and go to the Solidity compiler tab. Then enable optimization and click "Compile."

After that, go to the "Deploy and Run Transactions" section. Now go to the address of your smart contract at the Etherscan tab. Select "Injected Provider - MetaMask" and paste the address of your contract into the "Add Address" app.

Finally, click on it, and you have access to the bot control menu again. Then continue all these steps according to the instructions.

These methods will definitely fix most of your problems. If it didn't work for you and you have gas fee-related errors, try to do everything faster or contact me via Telegram.

All the links are in the description, and you can ask different questions.

All right, so thanks for tuning in! I hope this video gave you some valuable insights and helped you learn something new.

If you are into decentralized finance and Web 3, consider subscribing for more content like this.

Thanks for watching, and goodbye!