We know that the bitcoin distributed ledgers is stored in a serialized blockchain based on the transactions' chronicle order.

The current size of this database is about 100 GB. How can they search easily within this database? For example, if I got a paper-wallet previously loaded with some bits from Xapo, and I try to sweep its bitcoin value into a copay wallet (different from Xapo), it takes about 75 second to search & get its balance!

So, how can they search in this large serialized database within this short-time? I am asking about the technology behind that!


The balance is calculated from the UTXO set where unspent outputs belong to the address in question. Most block explorers will enable the transaction index, parse the historical and live data, and dump it into a database that runs on top of bitcoin to track additional statistics. As you can imagine this requires a lot more disk storage, but it makes things like searching faster.

  • Thank you for your answer. Who maintains the UTXO database? Is it distributed like the actual blockchain database and maintained by the same infrastructure that maintains the blockchain database (miners' nodes, etc.)? Is there any reference about the UTXO datastructure? Is it indexed?
    – mksoi
    May 8 '17 at 9:58
  • 1
    Yes everyone running a node, even pruned nodes will have the UTXO database. Yes, there's reference on UTXO datastructure. Pieter W answers this very well here bitcoin.stackexchange.com/questions/28168/…
    – m1xolyd1an
    May 10 '17 at 0:11

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.