Deploy with Remix IDE
Last updated
Was this helpful?
Last updated
Was this helpful?
is a no-setup tool with a GUI for developing smart contracts. Used by experts and beginners alike, Remix will get you going in no time.
Remix is available as , , and even . In this page, we will use the web-based version.
Go to .
The Remix IDE opens in your browser.
Remix IDE allows you to directly start working on an ERC20-compatible token. You can of course deploy your own smart contract through Remix IDE, but for the purpose of this tutorial, we'll stick to ERC20.
Click the "ERC20" button, right below the "Start Coding" button.
Once you click, Remix IDE loads a standard workspace with several folders and files that appear in the File Explorer on the left. Click in the /contracts/MyToken.sol
to display this:
As you can, see MyToken.sol smart contract already imports the ERC20.sol
and the ERC20Permet.sol
smart contracts.
Open the .deps/npm/@openzeppelin/contracts/token/ERC20/ERC20.sol
file. This is the ERC20 contract provided by OpenZeppelin.
You can customise the MyToken.sol
smart contract right from Remix IDE (starting with a name and symbol), in order to fit your idea of a token for Chiliz Chain.
You should also rename the file itself.
Click "Compile" (the green arrow)
If there are no mistakes in your changes, Remix IDE should display a green checkmark in the "Solidity Compiler" menu on the left:
Open the "Deploy & run transactions" section.
Select "Injected Provider - MetaMask" in the "Environment" dropdown menu in order to link your MetaMask account.
Make sure that your contract is selected
Click "Deploy".
Make sure to have enough CHZ on your wallet to pay for transactions!
Your MetaMask wallet should open automatically.
8. Click "Confirm" to link your MetaMask Wallet with your token's smart contract.
You should receive a notification confirming the transaction within a few seconds.
10. In your MetaMask Wallet, under the "Activity" tab, you will see the contract deployment information. Click it to see all the information about it.
Your contract is now deployed on Chiliz Chain!
is an open-source platform for building secure dApps.
In addition to several security and auditing services, they provide , free for the community to use in their projects. development.
As such, OpenZeppelin contracts are considered industry standards, and you can safely use them. Remix IDE uses the here.
Optionally, you can view the deployed contract on the .