I am currently trying to mint some ERC-721 non-fungible tokens to the OpenSea website.

I am following this tutorial and have got everything working on the testnet. My collection has been minted on Rinkeby and I am now ready to move on to the main net.

This is the step of the tutorial I am now on.

The tutorial code I have been using is found here and, running on the testnet I can see that three steps involve gas fees: The migration step, the deployment step and each minting step.

I've not submitted many smart contracts before and I've never really fiddled with gas prices. I know I probably have to set a gas price based on the current standard gas but I'm not sure how.

My question is this:

Where in the `opensea-creatures' example code is the gas price set for each of the three of the steps I mentioned above? Should I change these prices or is there something automatic which handles this for OpenSea? (I understand OpenSea's has a lot of workarounds so people don't have to pay gas when minting but think these probably don't apply here)

Also, on a side note; is gas fee usually specified in Wei units?


1 Answer 1


The gas price is set by the signer. If you are connecting this code to Geth, MetaMask or a similar wallet, you can set the gas prices there.

  • Okay I see... So just to confirm: I just change the gas price in metamask and then whatever smart contract I deploy using my metamask details will just use that gas price? Thank you!
    – JDoe2
    Commented Sep 13, 2021 at 1:44
  • This confuses me because when I deploy to rinkeby the deployment step uses a gas price of 20 gwei whilst the minting steps use a price of 1 gwei - shouldn't they be using the same price from metamask though?
    – JDoe2
    Commented Sep 13, 2021 at 1:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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