5

I want to get the byte code of a deployed contract. How can I get it? Is there a special function in web3.js? I haven't found any.

1 Answer 1

4

According to the docs, you can use this method:

web3.eth.getCode(addressHexString [, defaultBlock] [, callback])

Where addressHexString is the address your contract was deployed at.

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.