Mining
NULL is mined with Equihash (144, 5) on CPUs. You can mine solo with nulld or from the desktop wallet's Node page, or point your hardware at a public pool. This page covers solo mining and the readiness rules every miner follows. Pool operators should read the pool guide.
Before you start
- A payout address. Mainnet addresses start with
null1. Create a wallet with the desktop wallet ornulld create, or print one withnulld keygen(see Command line). - Memory. An Equihash
(144, 5)solver needs about 1.8 GB of memory per thread. - A synced node with peers. On mainnet a node hands out no work until it has a peer and has caught up with the network. See the readiness gate.
The block subsidy starts at 9.7 NULL, plus the fees of the block's transactions. Blocks come every 120 seconds on average. A reward mined at height h is spendable from height h + 100.
Solo mining with nulld
Pass --mine with your address to nulld run:
nulld run --network main --mine null1... --mining-threads 4
| Flag | Meaning |
|---|---|
--mine <address> | Mine and pay every block found to this address. |
--mining-threads <n> | Worker threads. Default 1. Ignored without --mine. |
--metrics <ip:port> | Optional. Serve Prometheus metrics at GET /metrics. |
Each worker builds a template, grinds a bounded number of nonces from a random start, and asks for a fresh template, so workers explore disjoint nonces and drop stale work when the tip moves. The first start builds the coinbase proving key, which takes a few seconds.
The log prints mined block <height> <hash> for every block this node finds. With --metrics, null_blocks_mined{state="found"} and null_blocks_mined{state="in_chain"} count the blocks found since start and how many of them are still on the main chain.
See Run a node for the data directory, peers and the rest of nulld run.
Mining in the desktop wallet
The desktop wallet's Node page has a Mining card:
- An on/off switch and a thread slider, from 1 to the machine's CPU count. The default is half the CPUs, so the machine stays usable.
- Mining needs an unlocked wallet and always pays the wallet's main address (index 0). While the wallet is locked the switch is disabled; locking stops the miner.
- Moving the slider while mining restarts the miner with the new count. Stopping takes at most one solve and happens in the background.
- The card shows the payout address, how many blocks this session found, and how many of those are in the main chain.
- The switch saves
mineandmining_threadstonull.conf. Withmine = truesaved, mining starts again on the next unlock.
If you turn mining on before the node is ready, the badge reads Waiting for sync with the reason, and the miner uses no CPU until the node is ready. See Desktop wallet.
The mining readiness gate
A block mined on an old tip would be discarded once the node caught up, so a node only hands out mining work when it is ready:
| Network | Ready when |
|---|---|
| main | At least one peer has finished its handshake, the node is not downloading blocks, and no peer reports a longer chain. |
| test | The node is not downloading blocks and no peer reports a longer chain. A lone test node mines. |
What you see while the node is not ready:
- The built-in miner and the desktop miner wait and retry each second, without using CPU. The log says
mining waits: no peers yetormining waits: catching up with the network, thenmining resumes: caught up with the network. getblocktemplatefails with error code-2andnot ready to mine: no peers yetornot ready to mine: catching up with the network. See Mining methods.- With
--metrics, the gaugenull_mining_readyis0, and1once the node hands out work.
Spending rewards
Each block you find is one note in your wallet. A transaction can spend at most 16 notes, so after many blocks, merge rewards into larger notes before a large payment:
- In the desktop wallet: Send, then Consolidate inputs.
- From the command line, with the wallet file not open elsewhere:
nulld consolidate --wallet miner.redb --rpc-token-file /path/to/rpc.token --dry-run
nulld consolidate --wallet miner.redb --rpc-token-file /path/to/rpc.token
--dry-run shows the input count, transaction count, destination and total fee without sending anything. Each batch merges up to 16 notes into your main address. See the exchange guide for the details.
Public pools
Pools run by third parties. Check each pool's own page for its address, port, fee and payout rules.
| Pool | Link |
|---|---|
| Aria Pool | pool.ariabrain.com |
| NinjaRaider | ninjaraider.com |
| rplant | pool.rplant.xyz |
| 88pool | null.88pool.com |
To run your own pool, see the pool guide.