I'm creating an ERC20 token on Remix and using EIP20.sol from Consensys. I'm using this video tutorial as a guide - https://www.youtube.com/watch?v=d5EipPVafsA

It's been helpful, however I have one issue. When it comes to deploy I get far less tokens than I intended the total supply to be.

I want 8,000,000 tokens with a 18 decimal places.

I used in: 8000000,"TOKENNAME",18,"TOKENTICKER"

and the total supply is... 0.000000000008

Why is this and how should I change the numbers to make it 8 million supply with 18 decimals?


This is due to two different "token amounts" being used. One is for display purposes and one is for implementation purposes and they don't match each other unless you use decimals=0.

Edit: forgot to specifically answer your question, thanks @Rob for pointing it out :) so the decimals:

Needs to be 8,000,000 x 10^^18.

You can read more for example here: https://ethereum.stackexchange.com/a/72481/31933

  • Needs to be 8,000,000 x 10^^18. – Rob Hitchens Jul 12 '19 at 17:20
  • Thanks for the heads up, edited my answer :) – Lauri Peltonen Jul 12 '19 at 17:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.