Skip to main content

getblock RPC Method

Returns information about the block.

Updated on
Feb 03, 2026

Parameters

blockhash
string
REQUIRED

The hash of the block

verbosity
integer

default = 1, 0 for hex-encoded data, 1 for a JSON object, 2 for JSON object with transaction data, and 3 for JSON object with transaction data including prevout information for inputs

Returns

result
string | object

Hex-encoded serialized block when verbosity is 0, or a block JSON object when verbosity is 1 or higher.

hash
string

The block hash

confirmations
integer

The number of confirmations

height
integer

The block height

version
integer

The block version

versionHex
string

The block version formatted in hexadecimal

merkleroot
string

The merkle root

time
integer

The block time in seconds since epoch (Unix time)

mediantime
integer

The median block time in seconds since epoch (Unix time)

nonce
integer

The nonce

bits
string

The bits

target
string

The target in hexadecimal

difficulty
number

The difficulty

chainwork
string

Expected total amount of work in the chain up to this block, in hexadecimal

nTx
integer

The number of transactions in the block

previousblockhash
string

The hash of the previous block

nextblockhash
string

(Optional) The hash of the next block (omitted for the chain tip)

strippedsize
integer

The stripped size of the block

size
integer

The size of the block

weight
integer

The weight of the block

tx
array

Transaction IDs (verbosity 1) or full transaction objects (verbosity 2+)

coinbase_tx
object

Coinbase transaction summary for the block

version
integer

Transaction version

locktime
integer

Transaction lock time

sequence
integer

Coinbase input sequence

coinbase
string

Coinbase payload hex

witness
string

Witness data for the coinbase input (hex on docs-demo)

error
object | null

(Optional) JSON-RPC error when the request failed; omitted or null on success

code
integer

Error code

message
string

Error message

Request
Response
1
{
2
"jsonrpc": "2.0",
3
"result": {
4
"hash": "00000000c937983704a73af28acdec37b049d214adbda81d7e2a3dd146f6ed09",
5
"confirmations": 932587,
6
"height": 1000,
7
"version": 1,
8
"versionHex": "00000001",
9
"merkleroot": "fe28050b93faea61fa88c4c630f0e1f0a1c24d0082dd0e10d369e13212128f33",
10
"time": 1232346882,
11
"mediantime": 1232344831,
12
"nonce": 2595206198,
13
"bits": "1d00ffff",
14
"target": "00000000000000000001fca10000000000000000000000000000000000000000",
15
"difficulty": 1,
16
"chainwork": "000000000000000000000000000000000000000000000000000003e903e903e9",
17
"nTx": 1,
18
"previousblockhash": "0000000008e647742775a230787d66fdf92c46a48c896bfbc85cdc8acc67e87d",
19
"nextblockhash": "00000000a2887344f8db859e372e7e4bc26b23b9de340f725afbf2edb265b4c6",
20
"strippedsize": 216,
21
"size": 216,
22
"weight": 864,
23
"tx": [
24
"fe28050b93faea61fa88c4c630f0e1f0a1c24d0082dd0e10d369e13212128f33"
25
]
26
},
27
"id": 1
28
}
1
{
2
"jsonrpc": "2.0",
3
"result": {
4
"hash": "00000000c937983704a73af28acdec37b049d214adbda81d7e2a3dd146f6ed09",
5
"confirmations": 932587,
6
"height": 1000,
7
"version": 1,
8
"versionHex": "00000001",
9
"merkleroot": "fe28050b93faea61fa88c4c630f0e1f0a1c24d0082dd0e10d369e13212128f33",
10
"time": 1232346882,
11
"mediantime": 1232344831,
12
"nonce": 2595206198,
13
"bits": "1d00ffff",
14
"target": "00000000000000000001fca10000000000000000000000000000000000000000",
15
"difficulty": 1,
16
"chainwork": "000000000000000000000000000000000000000000000000000003e903e903e9",
17
"nTx": 1,
18
"previousblockhash": "0000000008e647742775a230787d66fdf92c46a48c896bfbc85cdc8acc67e87d",
19
"nextblockhash": "00000000a2887344f8db859e372e7e4bc26b23b9de340f725afbf2edb265b4c6",
20
"strippedsize": 216,
21
"size": 216,
22
"weight": 864,
23
"tx": [
24
"fe28050b93faea61fa88c4c630f0e1f0a1c24d0082dd0e10d369e13212128f33"
25
]
26
},
27
"id": 1
28
}
Don't have an account yet?
Create your Quicknode endpoint in seconds and start building
Get started for free