21

Is there a query that will return the size of the UTXO database? Specifically, the total number of unspent outputs.

23

Bitcoin Core provides the gettxoutsetinfo RPC that has exactly the information you want. Note, it takes that call up to a minute or two to run (and maybe longer as the UTXO set keeps growing).

Here's what my node says right now:

{
  "height": 442313,
  "transactions": 15237948,
  "txouts": 43194647,
  "bytes_serialized": 1635888675,
  "total_amount": 16028761.10201779
}

Current and historical data may be found on Statoshi.info's UTXO page.

  • It seems to me that having more than one sample output does not benefit the answer, as it will eventually be outdated inevitably. I'd probably roll back to your initial answer, or replace the old output with the current. Although, it is somewhat interesting to see that within half a year the number of txouts has almost doubled. – Murch Aug 10 '15 at 14:46
  • @Murch The number of outputs has just about doubled now, to 33409889. – Anonymous Aug 29 '15 at 13:21
  • Does all the nodes store UTXO database? @Murch♦ – alper Jan 3 '18 at 16:33
  • 1
    @Alper: Yes, all full nodes have the complete UTXO Set. – Murch Jan 4 '18 at 0:18

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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