2

As I know, there is a light node version called SPV. for now I have started a full node and it has downloaded 82222 blocks, but I don't want to have a full node with full blockchain, my purpose is to have a node that provide me:

  • check balance or unspent amount for an address
  • sign and broadcast a transaction

is this possible?

8
  • 1
    bcoin is a nodejs Bitcoin library with both full and SPV node applications: GitHub.com/bcoin-org/bcoin
    – pinhead
    May 3 '20 at 13:40
  • @pinhead thank you, only can I ask a question? I have downloaded bitcoin source from here github.com/bitcoin/bitcoin and after all steps I can run bitcoin-cli. now it downloaded blocks 8222, but I don't want to download 300GB of blocks and only I want to download headers. this has any line config in bitcoin.conf or Is something completely separate from bitcoin core? May 3 '20 at 13:46
  • 1
    Bitcoin Core does not have an SPV mode. It can serve SPV clients but by design it is only a full node. If disk space is your only issue you can run it with pruning on. A pruned node deletes old blocks from disk but still maintains a complete UTXO set which is sufficient for full validation.
    – pinhead
    May 3 '20 at 13:48
  • 1
    Bcoin is an alternative implementation of the bitcoin protocol. It was written from scratch in nodejs and shares very little code in common with Bitcoin Core which is written in C++. Some open source libraries like the crypto library libsecp256k1 are included with license. But otherwise it is a complete rewrite including networking, wallet, and block validation.
    – pinhead
    May 3 '20 at 13:54
  • 1
    Yeah sounds like you get the concept. Please learn more about the trade offs involved with SPV before using it. I'm not aware of any useful PHP bitcoin library.
    – pinhead
    May 3 '20 at 14:03
2

By design, Bitcoin Core is a fully validating Bitcoin node and does not have an SPV client mode.

If disk space is your primary concern, you can run Bitcoin Core with pruning active. This will delete old blocks from disk but maintain a full UTXO set which is sufficient for full blockchain validation.

Bitcoin Core can serve SPV clients, although there has been discussion to deprecate this service or at least switch the service off by default. Before using an SPV wallet yourself, you should understand the tradeoffs for both security and privacy.

There are other software libraries capable of running a bitcoin wallet with Simple Payment Verification. One such library is bcoin which is written in nodejs:

https://GitHub.com/bcoin-org/bcoin

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.