0

I need to find an API giving the total number of unique addresses used on the Ethereum Classic blockchain.

For example, the following API provides it for Ethereum: https://etherscan.io/chart/address

Is there a similar API for ETC?

  • 3
    Total number of unique addresses in Ethereum Classic is 1461501637330902918203684832716283019655932542976 (2^160), but probably you don't need all of them. Could you clarify what addresses you want to count? Maybe all addresses with non-zero balance? – Mikhail Vladimirov Jan 20 at 7:05
  • I meant total number of unique addresses used in transactions or, in other words, total number of unique addresses ever seen on the blockchain Hope that's clear. – Esref Jan 20 at 7:31
  • 1
    @Esref: That's not clearer than the original question. There are 2^160 unique addresses, just like the comment above states. How many of those have ever been used - you'd need to scan the entire blockchain and count them. – goodvibration Jan 20 at 8:20
  • 1
    You need to further clarify what does it mean for an address to be "seen" on the blockchain. For example, if some contract checks ether balance of an address just to find out, that the balance is zero, does it count? Or more complicated case: some contract checks ERC-20 token balance of an address. At EVM level this would be just reading from storage slot, no way to reliably distinguish from other reads, not related to addresses. – Mikhail Vladimirov Jan 20 at 9:22
  • You can see this value for ETH here: etherscan.io/chart/address That's exactly what I want to have for ETC. Yes @goodvibration, if I cannot find any API, I am planning to scan all transactions and count unique addresses. Mikhail Vladimirov, I am not sure I have understood what you meant but I want to get all unique addresses that have ever seen on transactions. The definition from the above link is: "The chart shows the total distinct numbers of address on the Ethereum blockchain" – Esref Jan 20 at 13:05
2

It is hard to tell what exactly Etherscan.io counts on that chart. I tried to reproduce it via Google BigQuery but didn't manage to get the same result. Here is what I tried:

  1. All addresses Google has recorded balance for:
SELECT COUNT(*)
FROM `bigquery-public-data.crypto_ethereum.balances`;

Gives me 104,951,247 for Ethereum and 73,653,935 for Ethereum Classic.

  1. All addresses a transaction, or some kind of internal transaction was ever send to or from:
SELECT count(*)
FROM (
  SELECT `from_address`
  FROM `bigquery-public-data.crypto_ethereum.transactions`
  UNION DISTINCT 
  SELECT  `to_address`
  FROM `bigquery-public-data.crypto_ethereum.transactions`
  UNION DISTINCT 
  SELECT  `from_address`
  FROM `bigquery-public-data.crypto_ethereum.traces`
  UNION DISTINCT 
  SELECT  `to_address`
  FROM `bigquery-public-data.crypto_ethereum.traces`
)

Gives me 105,040,917 for Ethereum and 73,693,901 for Ethereum Classic.

You may play with the queries above and probably you will find out how Etherscan.io counts addresses.

  • Thanks @Mikhail Vladimirov, I hadn't realized that ETC was on BigQuery. I also need to find this number for EOS. However, EOS is not on the BigQuery public dataset. Do you also know a way to calculate this number for EOS? – Esref Jan 25 at 8:24
  • 1
    No, I don't know, but maybe this will help: reddit.com/r/EOSDev/comments/af98ux/… – Mikhail Vladimirov Jan 25 at 10:33

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.