2

I have conflicting information about this. I thought reading the blockchain was free but writing was at a cost.

Now someone says to me that executing any contract even just reading data has a gas cost.

I saw a discussion here - https://www.reddit.com/r/ethereum/comments/49t2jc/get_data_from_the_blockchain_without_using_gas/

Has anyone the real classification about this?

5

Reading data from Blockchain does not cost you any gas. Invoking any function of contract with sendTransaction method will cost you gas, even though it does not do anything as you are adding this transaction to the blockchain, which is why there is a method called call which just executes your contract locally and gives you the result, it does not change anything in blockchain and does not add any transaction to the blockchain, so it does not cost you any gas.

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.