getblockchaininfo RPC Method
Parameters
This method does not accept any parameters
Returns
chain
The name of the current network (main, test, regtest)
blocks
The height of the most-work fully-validated chain. The genesis block has height 0
headers
The current number of headers validated
bestblockhash
The hash of the current best block
difficulty
The difficulty of the highest height block
time
The time for the current best block
mediantime
The median time for the current best block
verificationprogress
An estimate of verification progress [0..1]
initialblockdownload
(debug information) An estimate of whether this node is in Initial Block Download mode
chainwork
Total amount of work in active chain in the hexadecimal form
size_on_disk
The estimated size of the block and undo files on disk
pruned
It indicates if the blocks are subject to pruning
warnings
Any network and blockchain warnings
error
The error message, if any
Request
1curl https://docs-demo.btc.quiknode.pro/ \2-X POST \3-H "Content-Type: application/json" \4--data '{ "method": "getblockchaininfo" }'5
Don't have an account yet?
Create your QuickNode endpoint in seconds and start building
Get started for free