Inside Bitcoin
Opening the selected file…
Inside Bitcoin
Opening the selected file…
The code behind the network, with room to understand it.
Release published 2026-10-28 · Snapshot fetched 2026-11-01. Latest stable release at fetch time; development branches and Git history are excluded. Only the selected code window and visible folders load here.
1Bitcoin Core version 0.12.0 is now available from:3<https://bitcoin.org/bin/bitcoin-core-0.12.0/>5This is a new major version release, bringing new features and other improvements.7Please report bugs using the issue tracker at github:9<https://github.com/bitcoin/bitcoin/issues>11Upgrading and downgrading12=========================14How to Upgrade15--------------17If you are running an older version, shut it down. Wait until it has completely18shut down (which might take a few minutes for older versions), then run the19installer (on Windows) or just copy over /Applications/Bitcoin-Qt (on Mac) or20bitcoind/bitcoin-qt (on Linux).22Downgrade warning23-----------------25### Downgrade to a version < 0.10.027Because release 0.10.0 and later makes use of headers-first synchronization and28parallel block download (see further), the block files and databases are not29backwards-compatible with pre-0.10 versions of Bitcoin Core or other software:31* Blocks will be stored on disk out of order (in the order they are32received, really), which makes it incompatible with some tools or33other programs. Reindexing using earlier versions will also not work34anymore as a result of this.36* The block index database will now hold headers for which no block is37stored on disk, which earlier versions won't support.39If you want to be able to downgrade smoothly, make a backup of your entire data40directory. Without this your node will need start syncing (or importing from41bootstrap.dat) anew afterwards. It is possible that the data from a completely42synchronised 0.10 node may be usable in older versions as-is, but this is not43supported and may break as soon as the older version attempts to reindex.45This does not affect wallet forward or backward compatibility.47### Downgrade to a version < 0.12.049Because release 0.12.0 and later will obfuscate the chainstate on every50fresh sync or reindex, the chainstate is not backwards-compatible with51pre-0.12 versions of Bitcoin Core or other software.53If you want to downgrade after you have done a reindex with 0.12.0 or later,54you will need to reindex when you first start Bitcoin Core version 0.11 or55earlier.57Notable changes58===============60Signature validation using libsecp256k161---------------------------------------63ECDSA signatures inside Bitcoin transactions now use validation using64[libsecp256k1](https://github.com/bitcoin-core/secp256k1) instead of OpenSSL.66Depending on the platform, this means a significant speedup for raw signature67validation speed. The advantage is largest on x86_64, where validation is over68five times faster. In practice, this translates to a raw reindexing and new69block validation times that are less than half of what it was before.71Libsecp256k1 has undergone very extensive testing and validation.73A side effect of this change is that libconsensus no longer depends on OpenSSL.75Reduce upload traffic76---------------------78A major part of the outbound traffic is caused by serving historic blocks to79other nodes in initial block download state.81It is now possible to reduce the total upload traffic via the `-maxuploadtarget`82parameter. This is *not* a hard limit but a threshold to minimize the outbound83traffic. When the limit is about to be reached, the uploaded data is cut by not84serving historic blocks (blocks older than one week).85Moreover, any SPV peer is disconnected when they request a filtered block.87This option can be specified in MiB per day and is turned off by default88(`-maxuploadtarget=0`).89The recommended minimum is 144 * MAX_BLOCK_SIZE (currently 144MB) per day.91Whitelisted peers will never be disconnected, although their traffic counts for92calculating the target.94A more detailed documentation about keeping traffic low can be found in95[/doc/reduce-traffic.md](/doc/reduce-traffic.md).97Direct headers announcement (BIP 130)98-------------------------------------100Between compatible peers, [BIP 130]101(https://github.com/bitcoin/bips/blob/master/bip-0130.mediawiki)102direct headers announcement is used. This means that blocks are advertised by103announcing their headers directly, instead of just announcing the hash. In a104reorganization, all new headers are sent, instead of just the new tip. This105can often prevent an extra roundtrip before the actual block is downloaded.107Memory pool limiting108--------------------110Previous versions of Bitcoin Core had their mempool limited by checking111a transaction's fees against the node's minimum relay fee. There was no112upper bound on the size of the mempool and attackers could send a large113number of transactions paying just slighly more than the default minimum114relay fee to crash nodes with relatively low RAM. A temporary workaround115for previous versions of Bitcoin Core was to raise the default minimum116relay fee.118Bitcoin Core 0.12 will have a strict maximum size on the mempool. The119default value is 300 MB and can be configured with the `-maxmempool`120parameter. Whenever a transaction would cause the mempool to exceed121its maximum size, the transaction that (along with in-mempool descendants) has122the lowest total feerate (as a package) will be evicted and the node's effective123minimum relay feerate will be increased to match this feerate plus the initial124minimum relay feerate. The initial minimum relay feerate is set to1251000 satoshis per kB.127Bitcoin Core 0.12 also introduces new default policy limits on the length and128size of unconfirmed transaction chains that are allowed in the mempool129(generally limiting the length of unconfirmed chains to 25 transactions, with a130total size of 101 KB). These limits can be overridden using command line131arguments; see the extended help (`--help -help-debug`) for more information.133Opt-in Replace-by-fee transactions134----------------------------------136It is now possible to replace transactions in the transaction memory pool of137Bitcoin Core 0.12 nodes. Bitcoin Core will only allow replacement of138transactions which have any of their inputs' `nSequence` number set to less139than `0xffffffff - 1`. Moreover, a replacement transaction may only be140accepted when it pays sufficient fee, as described in [BIP 125]141(https://github.com/bitcoin/bips/blob/master/bip-0125.mediawiki).143Transaction replacement can be disabled with a new command line option,144`-mempoolreplacement=0`. Transactions signaling replacement under BIP125 will145still be allowed into the mempool in this configuration, but replacements will146be rejected. This option is intended for miners who want to continue the147transaction selection behavior of previous releases.149The `-mempoolreplacement` option is *not recommended* for wallet users seeking150to avoid receipt of unconfirmed opt-in transactions, because this option does151not prevent transactions which are replaceable under BIP 125 from being accepted152(only subsequent replacements, which other nodes on the network that implement153BIP 125 are likely to relay and mine). Wallet users wishing to detect whether154a transaction is subject to replacement under BIP 125 should instead use the155updated RPC calls `gettransaction` and `listtransactions`, which now have an156additional field in the output indicating if a transaction is replaceable under157BIP125 ("bip125-replaceable").159Note that the wallet in Bitcoin Core 0.12 does not yet have support for160creating transactions that would be replaceable under BIP 125.163RPC: Random-cookie RPC authentication164-------------------------------------166When no `-rpcpassword` is specified, the daemon now uses a special 'cookie'167file for authentication. This file is generated with random content when the168daemon starts, and deleted when it exits. Its contents are used as169authentication token. Read access to this file controls who can access through170RPC. By default it is stored in the data directory but its location can be171overridden with the option `-rpccookiefile`.173This is similar to Tor's CookieAuthentication: see174https://www.torproject.org/docs/tor-manual.html.en176This allows running bitcoind without having to do any manual configuration.178Relay: Any sequence of pushdatas in OP_RETURN outputs now allowed179-----------------------------------------------------------------181Previously OP_RETURN outputs with a payload were only relayed and mined if they182had a single pushdata. This restriction has been lifted to allow any183combination of data pushes and numeric constant opcodes (OP_1 to OP_16) after184the OP_RETURN. The limit on OP_RETURN output size is now applied to the entire185serialized scriptPubKey, 83 bytes by default. (the previous 80 byte default plus186three bytes overhead)188Relay: New and only new blocks relayed when pruning189---------------------------------------------------191When running in pruned mode, the client will now relay new blocks. When192responding to the `getblocks` message, only hashes of blocks that are on disk193and are likely to remain there for some reasonable time window (1 hour) will be194returned (previously all relevant hashes were returned).196Relay and Mining: Priority transactions197---------------------------------------199Bitcoin Core has a heuristic 'priority' based on coin value and age. This200calculation is used for relaying of transactions which do not pay the201minimum relay fee, and can be used as an alternative way of sorting202transactions for mined blocks. Bitcoin Core will relay transactions with203insufficient fees depending on the setting of `-limitfreerelay=<r>` (default:204`r=15` kB per minute) and `-blockprioritysize=<s>`.206In Bitcoin Core 0.12, when mempool limit has been reached a higher minimum207relay fee takes effect to limit memory usage. Transactions which do not meet208this higher effective minimum relay fee will not be relayed or mined even if209they rank highly according to the priority heuristic.211The mining of transactions based on their priority is also now disabled by212default. To re-enable it, simply set `-blockprioritysize=<n>` where is the size213in bytes of your blocks to reserve for these transactions. The old default was21450k, so to retain approximately the same policy, you would set215`-blockprioritysize=50000`.217Additionally, as a result of computational simplifications, the priority value218used for transactions received with unconfirmed inputs is lower than in prior219versions due to avoiding recomputing the amounts as input transactions confirm.221External miner policy set via the `prioritisetransaction` RPC to rank222transactions already in the mempool continues to work as it has previously.223Note, however, that if mining priority transactions is left disabled, the224priority delta will be ignored and only the fee metric will be effective.226This internal automatic prioritization handling is being considered for removal227entirely in Bitcoin Core 0.13, and it is at this time undecided whether the228more accurate priority calculation for chained unconfirmed transactions will be229restored. Community direction on this topic is particularly requested to help230set project priorities.232Automatically use Tor hidden services233-------------------------------------235Starting with Tor version 0.2.7.1 it is possible, through Tor's control socket236API, to create and destroy 'ephemeral' hidden services programmatically.237Bitcoin Core has been updated to make use of this.239This means that if Tor is running (and proper authorization is available),240Bitcoin Core automatically creates a hidden service to listen on, without241manual configuration. Bitcoin Core will also use Tor automatically to connect242to other .onion nodes if the control socket can be successfully opened. This243will positively affect the number of available .onion nodes and their usage.245This new feature is enabled by default if Bitcoin Core is listening, and246a connection to Tor can be made. It can be configured with the `-listenonion`,247`-torcontrol` and `-torpassword` settings. To show verbose debugging248information, pass `-debug=tor`.250Notifications through ZMQ
Independent explanations by MyBitcoinExplorer. Not affiliated with or endorsed by Bitcoin Core. Guides are educational and do not replace the source or its tests.
Bitcoin Core source © its contributors, distributed under the MIT license. Original notices and bundled third-party licenses are retained in the source tree.