Generating your first ERC-20 token on 20lab.app
A detailed guide for generating an ERC-20 token on the 20lab.app platform, including connecting a wallet, selecting desired features, validating your token and deploying your token on a chosen blockchain. Additionally I will show you how you can use the dashboard to manage its functionality.
Step 1: Connecting a wallet
By clicking “Connect wallet” button you will see a popup menu appear where you can choose a wallet you use for web3. Huge variety of wallets are supported, including MetaMask, Coinbase Wallet and others which you can connect using the WalletConnect service in your wallet app.
In my case, this will be a MetaMask wallet as a Google Chrome extension. By clicking on it, a MetaMask window popup automatically opens and asks me to link my account to 20lab.app. The last part is to click connect and wait a few seconds until both of them are successfully connected.
If everything works right, you will see your account address in the top-right corner as well as the blockchain symbol your wallet is currently connected to.
Step 2: Choose the desired features
To begin generation, click the start button. You will be automatically navigated to the first part of the generation panel where you can start typing the details that you want your ERC-20 token to have.
In my case I will create a token with the following details:
- It will be done on the BSC Testnet blockchain
- Name: Medium Guide Token
- Symbol: MGT
- Initial supply: 1000000 MGT
- Decimals: 18 (default)
I will add one more feature, which is a mint function that enables token owner to mint more tokens up to the maximum supply cap whenever required.
To accomplish this I will enable the “Mintable” feature.
Mintable feature is enabled with 2,000,000 MGT max supply. Owner will be able to mint additional 1,000,000 MGT tokens after the token is live.
The next sections: optional & taxes are about other optional features and taxes in your token. I will explain this section in the next guide. For now I will keep it empty, because I don’t want any other features in my MGT token.
Now I’m at the last part of the panel. Here I can see all the features that will be present in the MGT token source code and double-check if they are right.
Summarizing, I will have:
- General functions that are included in every token
- Mint function controlled by owner
Step 3: Validating token configuration
After checking everything I can try to validate my token configuration.
Seems like everything worked smoothly and the deployment window appeared. My token is now ready to be deployed on the BSC Testnet blockchain.
Step 4: Deploy your token
By clicking “Deploy” I got a MetaMask popup asking me to confirm the deployment transaction. After clicking “Confirm” and waiting for blockchain confirmation, the MGT token will be live!
Confirmation time will depend on the blockchain chosen as well as the gas fee you provide for that transaction. That doesn’t mean that you need to redeploy the token if your transaction has been in a pending state for a long time. Once it is confirmed you will be able to view it in the dashboard.
In my case MGT was deployed in a few seconds. Thanks BSC Testnet for the quick confirmation. Here you can see it in the block explorer:
https://testnet.bscscan.com/token/0x2f80F2b161824cC1F2e00F2B5f8AfeBe3b4b27fE
Step 5: Dashboard
By clicking the “Dashboard” button in the navigation bar at the top of the page I can see my token is deployed.
Let’s see which functions are available for the owner to control.
Looks like there are a few of them:
- In the general section you will find a list of the functions available in each token (must-have in ERC-20).
- Ownable section will allow you to control ownership of the token.
- Mintable section will show you the mint functionality.
Let’s try the mint function. I will try to print 500,000 MGT tokens for myself. To do it, I will paste my address in the “To” field and put the correct amount in the “Amount” field.
After confirmation I can see the total supply was updated automatically below the token address. Same can be easily seen on the block explorer.
Looks like the MGT token works flawlessly and can be managed easily by the owner in the dashboard.
Thank you for reading this guide. I hope all the steps were explained accurately. If you still find some problems or have questions regarding the 20lab platform we will be glad to help and answer them on our Telegram chat & support group:
Thank you for using 20lab!