Skip to main content
In this guide you write, compile and deploy a contract to BOT Chain testnet using only your browser. Remix does the compiling and MetaMask signs the transaction.
Everything on this page uses testnet (chain 968). Get free test tokens from the faucet.

What you’ll build

A Counter contract deployed to BOT Chain testnet from Remix, which you can call from the Remix panel.

Prerequisites

Steps

1

Create the contract

Open remix.ethereum.org. In the File explorer, create a file named Counter.sol in the contracts folder and paste:
Counter.sol
2

Compile for Cancun

Open the Solidity compiler tab.
  1. Pick compiler version 0.8.28 or later.
  2. Open Advanced configurations and set EVM version to cancun.
  3. Click Compile Counter.sol.
The Cancun setting stops the compiler from using opcodes BOT Chain doesn’t support. See Supported EIPs.
3

Connect MetaMask

Open the Deploy & run transactions tab. Set Environment to Injected Provider - MetaMask (the exact label depends on your wallet). Approve the connection in MetaMask.Check that MetaMask is on BOT Chain Testnet. Remix shows the chain ID under the environment, and it should say 968.
4

Deploy

Select Counter in the Contract list and click Deploy. MetaMask opens. Check the network and fee, then confirm.BOT Chain needs a priority fee of at least 20 gwei. MetaMask reads this from the node, so the default fee works. See Gas and fees.

Verify it worked

  1. Under Deployed Contracts, expand Counter.
  2. Click count. It returns 0.
  3. Click increment and confirm in MetaMask.
  4. Click count again. It returns 1.
Copy the contract address from Remix and open https://scan.bohr.life/address/YOUR_ADDRESS to see it on BOTScan. To publish the source, follow Verify in the BOTScan UI and use the same compiler version, optimizer setting and EVM version you used in Remix.

Troubleshooting

MetaMask is on another network. Switch to BOT Chain Testnet in MetaMask; Remix updates on its own.
The EVM version is not set to cancun. Set it in Advanced configurations, compile again and redeploy.
Your wallet has no tBOT on testnet. Claim some from a faucet; see Get testnet tokens.

Next steps

Verify in the BOTScan UI

Publish your source code by hand.

Choose a toolchain

Move to Hardhat or Foundry when your project grows.
Last modified on October 3, 2026