6

How can I find the current blockchain size? (Obviously, I mean without downloading and installing a client, downloading the blockchain, and measuring on disk.)

I would also like a way to determine the blockchain size for expanse, ETC, etc.

3
  • 3
    You effectively can't. It's dependent on which implementation you're using, what pruning mode you've used, the block size in your file system, and presumably various other things. There's no single figure. May 20, 2017 at 7:24
  • So how can I know ahead of time if I'm going to have enough disk space?
    – stone.212
    May 21, 2017 at 2:16
  • 1
    Richard if you want to make this comment into an answer, I will mark it correct.
    – stone.212
    May 30, 2017 at 5:45

4 Answers 4

3

[Creating an answer from my initial comment... ]

How can I find the current blockchain size?

You effectively can't determine a generalised, one-size-fits-all size. It's dependent on which implementation you're using, what pruning mode you've used, the block size in your file system, and presumably various other things. There's no single figure.

3
  • 1
    Richard this is significantly different from your original comment and raises a number of other questions without answering them. Also it brings in ideas that are obvious (like the fact that the blocksize changes) but which isn't related to my question (which is about finding the blockchain size and implies finding it at any one particular moment.)
    – stone.212
    Jun 6, 2017 at 0:01
  • Agreed - simplified back to the original. Jun 6, 2017 at 7:55
  • why the size is not displayed in the etherstat?
    – Sig Touri
    Jun 6, 2017 at 8:40
2

You could consider connecting to a hosted Ethereum node like Infura.

Then get the number of blocks and do some estimation based on average blocksize:

current chainsize = (chainsize at an earlier point of time date / number of blocks at an earlier point of time) * current number of blocks.

This would be an estimate only and you might need to update the average blocksize time to time in your app. And as it was mentioned by others the chain size also depends on the geth implementation and OS.

Ex. to connect to infura on ropsten:

const web3 = new Web3(new Web3.providers.HttpProvider("https://ropsten.infura.io/<yourinfurakey>"));

Here are more details about how to connect to http provider with truffle.

1
  • This is useful information but doesn't really answer the question, especially because I am also asking about ETC, etc. But it's useful for ETH in particular.
    – stone.212
    Jun 7, 2017 at 4:09
2

You can now use chainstats, a page made by Chainstack, a blockchain infrastructure provider (full disclosure, I'm a dev advocate at Chainstack and worked on this page).

This app displays the current size of all the public network Chainstack support based on the Protocol, node type (full or archive), and blockchain client.

It is automatically updated when the size changes in the resources required by the servers.

-1

you can find quite a lot of stats, including the chain size here:

https://ethstats.net/

3
  • the ethstats don't give the chain size!! it i am mistaken please provide a screenshoot or the right link
    – Badr Bellaj
    May 21, 2017 at 11:32
  • Also that only applies to ETH. Not a generic way of getting blockchain size for expanse, ETC,etc. as I specified. This is not an answer,
    – stone.212
    May 22, 2017 at 4:13
  • It doesn't give you the blockchain size.
    – kiradotee
    Nov 14, 2017 at 15:25

Your Answer

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

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