Free tools · Block headers

Bitcoin block header calculator

Paste the 80 bytes of a block header, or fill in its six fields. This page decodes every field, runs double SHA-256 in your browser, expands the target from nBits, and tells you whether the proof of work holds.

The header

Start from a known block, or type your own. Nothing leaves your browser; the hashing runs on this page.

Spaces and line breaks are ignored.

How a block header works

A Bitcoin block header is exactly 80 bytes: six fields in a fixed order. It is the only thing a miner hashes. The transactions in the block are not hashed directly; they are summarised by the merkle root, a single 32-byte fingerprint that sits inside the header. Change any transaction and the merkle root changes, so the header changes, so the hash changes.

Why the bytes look backwards

The four integer fields (version, time, bits, nonce) are stored little-endian, lowest byte first. The nonce 2083236893 is 0x7c2bac1d, and appears in the header as 1d ac 2b 7c. The two hash fields are stored in the byte order SHA-256 produced them, but block explorers print hashes reversed, as one large number. That is why a previous-block hash or merkle root copied from an explorer has to be byte-reversed before it goes into a header, and why the zeros that make a block valid sit at the end of the raw digest and at the front of the hash you normally see.

nBits, the target, and what PASS means

The bits field is a compact encoding of a 256-bit number called the target. Its first byte is a size and the other three are a coefficient: target = coefficient × 256(size − 3). For Bitcoin's first block, 0x1d00ffff expands to 00000000ffff followed by 52 zeros. A header passes when its double SHA-256 hash, read as a number, is less than or equal to that target. Leading zeros are a consequence of the rule, not the rule itself: that target forces at least 8 leading hex zeros, and block 0 happens to have 10.

The only way to find a passing header is to try nonces (and, when those run out, change the time or the merkle root) until one works. The leading zeros calculator shows how long that takes at any hash rate.

What this calculator does not check

It checks the proof of work on one header, nothing more. It does not check that the merkle root matches real transactions, that the previous block exists, or that the block belongs to any chain. That distinction matters for the second preload button. A Strike a Block plate is a standalone block mined by a real Bitcoin ASIC, and its proof of work passes here exactly as block 0's does. It is not on Bitcoin's blockchain: its previous-block field is all zeros, it extends nothing, and it is not a coin or token.

More tools

Have a real chip strike your own line, from $6.99. One sentence of yours, mined into a standalone block by a Bitcoin ASIC. Not on Bitcoin's blockchain; the proof of work is real.