Set Up Developer Environment
Configure your Hardhat or Foundry development environment for Mezo Testnet.
Before you begin
Before you can deploy applications, you will need an Ethereum wallet with testnet BTC to pay for the gas fees.
Hardhat
If you are new to Hardhat, use the Hardhat Quick Start guide to learn how to install and initialize your project.
To configure Hardhat to work with Mezo Testnet, set the following items in your Hardhat config file:
- Add an entry under
networksfor Mezo Testnet withurl: "https://rpc.test.mezo.org"andchainId: 31611. - In the
soliditysettings, addevmVersion: "london".
See the Getting Started Guide for the canonical Hardhat example.
Foundry
If you are new to Foundry, use the Foundry Getting Started guide to learn how to install and initialize your project.
To configure a Foundry project to work with Mezo Testnet, set the following items in your Foundry TOML file under [profile.default] or a preferred profile:
- Chain ID:
chain_id = 31611 - RPC:
eth_rpc_url = "https://rpc.test.mezo.org" - EVM Version:
evm_version = 'london'
See the Getting Started Guide for canonical Foundry settings.