Module 1: Installing & Running Bitcoin Core
Learning Objectives
By the end of this module, you will:
Understand what Bitcoin Core is and how it differs from wallets or Lightning nodes
Install and configure bitcoind in regtest mode
Use bitcoin-cli to connect, query, and control your node
Set up a persistent Bitcoin Core environment for future modules
Lesson Outline
What Is Bitcoin Core?
It is the reference implementation of the Bitcoin protocol and it Includes:
Includes:
bitcoind: the daemon that runs the full node
bitcoin-cli: the command-line tool to interact with it
Preparing Your System
Dependencies:
Linux/macOS (Ubuntu preferred)
2–4GB RAM minimum
Disk space: ~500MB for regtest; ~500GB+ for full mainnet node
Recommended Setup:
Use a clean VPS or local Linux machine
Optional: Use Docker for sandboxing (we’ll cover later)
Downloading Bitcoin Core
Choose the binary for your OS (Linux, Mac, Windows).
Verify the GPG signature (optional but best practice).
Launching in Regtest Mode
Regtest = “Regression Test” mode = your own private Bitcoin network.
This:
Starts the node in the background
Creates a local chain with zero blocks
No external network connection required
Connecting via bitcoin-cli
Once the daemon is running, connect using:
This should return JSON showing:
Chain: regtest
Blocks: 0
Headers: 0
VerificationProgress: 1.000000
Setting Up a bitcoin.conf File (Optional)
Located at ~/.bitcoin/bitcoin.conf
Restart with:
Running bitcoind as a Daemon
By default, bitcoind runs in the foreground. To run it in the background (as a daemon), simply add the -daemon flag:
This will:
Start the Bitcoin Core node in regtest mode
Fork it into the background so you can continue using the terminal
Create and use the default data directory at ~/.bitcoin/regtest
You can always check whether it’s running with:
To stop the daemon gracefully:
Basic Node Health Checks
After launching your node, verify it’s functioning properly with these checks:
Check the blockchain state:
Look for:
blocks: Should be 0 (initially)
initialblockdownload: Should be false
{text variant="highlight-01" weight="regular" %}chain: Should be regtest
Check your wallet:
If you haven't created a wallet yet, it will return an empty list. You can create one with:
Check node status:
Version
Local relay status
Network type (regtest)
Connection count (should be 0 in regtest)
Check available RPC commands:
This is useful to explore the full range of bitcoin-cli capabilities.
This shows:
Version
Local relay status
Network type (regtest)
Connection count (should be 0 in regtest)
Check available RPC commands:
This is useful to explore the full range of bitcoin-cli capabilities.
Activity
Run this sequence:
Start bitcoind in regtest mode.
Query the chain info with bitcoin-cli.
Generate your first block
Confirm you now have spendable coins in your wallet with: