How to create an ERC20 token using Remix

Deploying an ERC20 contract with Remix

It might seem hard. I assure you it’s not.

This guide works for any EVM-compatible blockchain. Ethereum, Binance Smart Chain, Fantom, Avalanche, and more. Anything that you can use Metamask with, it works.

Here’s how.

The code

The code is super simple.

Copy, paste, and edit in Remix.

// SPDX-License-Identifier: MIT

pragma solidity ^0.8.16;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

contract YourShitcoin is ERC20 {
  constructor() ERC20("Your Shitcoin", "YOURSHITCOINSYMBOL")  {
    _mint(msg.sender, 1000000 * 10 ** 18);

Here are three things you need to know.

  1. The first parameter in the constructor, “Your Shitcoin“, is the name of your token.
  2. The second parameter in the constructor, “YOURSHITCOINSYMBOL“, is your token’s symbol.
  3. The _mint function mints 1 million tokens, 1000000, edit this to whatever you want.

Operating Remix

This is where things get a tad more difficult. I’ll make it as simple as possible.

Delete the default contracts

Remix comes bundled with a bunch of default crap. Delete the contracts that it comes with.


Create a new contract file

Name it YourShitcoin.sol

image 1
image 2

Paste in the code from above

image 5

Make the relevant edits

image 6

My token is called Crypto Trading Ninja Token, which has CTNT as it’s symbol, and there are 100 tokens minted on creation.

Compile the contracts

First, change the compiler version.

image 7

This should match the pragma solidity version in the file.

Then hit Compile.

image 8

You should get a nice green tick.

Deploy your shitcoin with Metamask

I’m assuming you’ve already got some gas in your wallet…

Set your Environment to Injected Provider.

image 9

Select your compiled shitcoin from the dropdown.

image 10

Then click Deploy.

image 11

After confirming in your wallet, you will have successfully created your first shitcoin.

The address is visible below. Look in deployed contracts. You can add this to your Metamask to see your tokens in your wallet.

image 12
Previous Article
algorithmic stablecoins

List of Algorithmic Stablecoins

Next Article
web3 career

List of Crypto Jobs Sites

Related Posts