Skip to content

Bitcoin accepted at checkout  |  Ships from Laval, QC, Canada  |  Expert support since 2016

Regtest

Network & Protocol

Definition

Regtest (regression test mode) lets a developer run a completely private Bitcoin blockchain with the same basic rules as testnet, but with total control over block production. Instead of waiting for a peer-to-peer network, you generate blocks instantly on demand, which makes it the fastest and most deterministic way to develop and test Bitcoin software.

How it works

You start a node with -regtest, then call the generatetoaddress RPC to mine blocks whenever you need them. Difficulty is trivially low, so blocks appear immediately. Each regtest instance lives in its own data subdirectory that you can delete to wipe the chain and start fresh, giving repeatable test fixtures.

The 101-block warm-up

The first 150 regtest blocks each pay a 50 BTC subsidy. Because a coinbase reward must mature for 100 blocks before it can be spent, developers typically generate 101 blocks at the start so there is at least one spendable output to build transactions from. This same maturity rule is what makes regtest a faithful sandbox for testing fee logic, reorgs, and multi-party flows.

Regtest gives more control than Signet or Testnet because there is no external network at all. See also coinbase maturity for why the 101-block warm-up is required.

In Simple Terms

Regtest (regression test mode) lets a developer run a completely private Bitcoin blockchain with the same basic rules as testnet, but with total control over…

Explore the Full Glossary

Browse all Bitcoin mining terms from A to Z. Whether you are a beginner or expert, deepen your understanding of the mining ecosystem.

Mining Glossary

ASIC Miner Database

Compare 500+ miners with real-time profitability data, home mining scores, and detailed specs.

Compare Miners