Creating an ERC20 Token with Unlimited Supply

erc-20

When you initially create an ERC20 token, you must declare totalSupply. Is that the hard cap on the number of tokens you can create or is totalSupply rather just the initial token supply?

Best Answer

No, you can mint as many as you want, which will increase the total-supply (up to 2 ** 256 - 1).

Make sure that the contract has a mint function; it is not a part of the ERC20 standard as far as I remember.

You can add this function (or any other function for that matter), so long as you implement the standard itself.