<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:media="http://search.yahoo.com/mrss/"><channel><title><![CDATA[Bitcoin Briefly]]></title><description><![CDATA[Bitcoin guides, tutorials, explainers, history, culture, trivia, current events, and more]]></description><link>https://bitcoinbriefly.com/</link><image><url>https://bitcoinbriefly.com/favicon.png</url><title>Bitcoin Briefly</title><link>https://bitcoinbriefly.com/</link></image><generator>Ghost 3.39</generator><lastBuildDate>Thu, 09 Apr 2026 23:16:22 GMT</lastBuildDate><atom:link href="https://bitcoinbriefly.com/rss/" rel="self" type="application/rss+xml"/><ttl>60</ttl><item><title><![CDATA[UTXO Consolidation Explained]]></title><description><![CDATA[<p>Published: 2021-12-26 at block 715,851<br>Bitcoin Price: $50,100</p><h2 id="table-of-contents">Table of Contents</h2><ul><li><a href="#introduction">Introduction</a></li><li><a href="#what-is-a-utxo">What is a UTXO?</a></li><li><a href="#what-s-the-issue-with-having-too-many-utxos">What’s the issue with having too many UTXOs?</a></li><li><a href="#what-is-utxo-consolidation">What is UTXO Consolidation?</a></li><li><a href="#what-are-the-benefits-of-utxo-consolidation">What are the Benefits of UTXO Consolidation?</a></li><li><a href="#what-are-the-disadvantages-of-utxo-consolidation">What are the Disadvantages of UTXO Consolidation?</a></li><li><a href="#who-is-utxo-consolidation-useful-for">Who is UTXO Consolidation Useful</a></li></ul>]]></description><link>https://bitcoinbriefly.com/utxo-consolidation-explained/</link><guid isPermaLink="false">61c76818e84cd304f387e14d</guid><category><![CDATA[Explainers]]></category><dc:creator><![CDATA[Alex Min]]></dc:creator><pubDate>Sun, 26 Dec 2021 15:20:26 GMT</pubDate><media:content url="https://images.unsplash.com/photo-1554672723-b208dc85134f?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MnwxMTc3M3wwfDF8c2VhcmNofDR8fGNhc2glMjBmaXJlfGVufDB8fHx8MTY0MDQ2MDQyMw&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2000" medium="image"/><content:encoded><![CDATA[<img src="https://images.unsplash.com/photo-1554672723-b208dc85134f?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=MnwxMTc3M3wwfDF8c2VhcmNofDR8fGNhc2glMjBmaXJlfGVufDB8fHx8MTY0MDQ2MDQyMw&ixlib=rb-1.2.1&q=80&w=2000" alt="UTXO Consolidation Explained"><p>Published: 2021-12-26 at block 715,851<br>Bitcoin Price: $50,100</p><h2 id="table-of-contents">Table of Contents</h2><ul><li><a href="#introduction">Introduction</a></li><li><a href="#what-is-a-utxo">What is a UTXO?</a></li><li><a href="#what-s-the-issue-with-having-too-many-utxos">What’s the issue with having too many UTXOs?</a></li><li><a href="#what-is-utxo-consolidation">What is UTXO Consolidation?</a></li><li><a href="#what-are-the-benefits-of-utxo-consolidation">What are the Benefits of UTXO Consolidation?</a></li><li><a href="#what-are-the-disadvantages-of-utxo-consolidation">What are the Disadvantages of UTXO Consolidation?</a></li><li><a href="#who-is-utxo-consolidation-useful-for">Who is UTXO Consolidation Useful For?</a></li><li><a href="#how-do-i-consolidate-utxos">How do I Consolidate UTXOs?</a></li><li><a href="#what-is-utxo-batching">What is UTXO Batching?</a></li><li><a href="#what-is-utxo-management">What is UTXO Management?</a></li><li><a href="#what-is-utxo-management">Conclusion</a></li></ul><h2 id="introduction">Introduction</h2><p>Sending Bitcoin transactions can get expensive. In previous blog posts, we’ve explored ways to mitigate transaction fees by:</p><ol><li>Sending transactions from <a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/#prefix-bc1-native-segwit-bech32-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-">Native SegWit Bech32 addresses</a> and</li><li>Setting <a href="https://bitcoinbriefly.com/so-your-bitcoin-transaction-is-stuck/#other-techniques-to-reduce-transaction-fees-and-further-fee-optimization">1 sat/vbyte fee rates</a> for your transactions</li></ol><p>Today, we’ll explore another way to <strong>save on mining fees: UTXO consolidation</strong>. </p><p>But first…</p><h2 id="what-is-a-utxo">What is a UTXO?</h2><figure class="kg-card kg-embed-card"><iframe width="356" height="200" src="https://www.youtube.com/embed/ZX5UOPRPQhc?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></figure><p><strong>A UTXO (Unspent Transaction Output)</strong> is an amount of bitcoin assigned to a Bitcoin address. Each time you receive any amount of bitcoin, you’re actually receiving a UTXO.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/UTXOs-received-at-various-addresses.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/UTXOs-received-at-various-addresses.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/UTXOs-received-at-various-addresses.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/12/UTXOs-received-at-various-addresses.png 1600w, https://bitcoinbriefly.com/content/images/2021/12/UTXOs-received-at-various-addresses.png 1620w" sizes="(min-width: 720px) 720px"><figcaption>Example: UTXOs Received at Various Addresses</figcaption></figure><p>Contrary to popular belief, Bitcoin is not a system of accounts or balances. Instead, there are only UTXOs assigned to various addresses. </p><p>Your wallet <strong>sums up all your UTXOs to calculate your bitcoin balance</strong>.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/Wallet-calculates-balance-sum-utxos-at-various-addresses.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/Wallet-calculates-balance-sum-utxos-at-various-addresses.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/Wallet-calculates-balance-sum-utxos-at-various-addresses.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/12/Wallet-calculates-balance-sum-utxos-at-various-addresses.png 1600w, https://bitcoinbriefly.com/content/images/2021/12/Wallet-calculates-balance-sum-utxos-at-various-addresses.png 1730w" sizes="(min-width: 720px) 720px"><figcaption><em>Example: Wallets calculate balances by summing up UTXOs at various addresses</em></figcaption></figure><p>So what happens when you send bitcoin to another person?</p><p>To better visualize UTXOs in a Bitcoin transaction, let’s use physical cash as an example. </p><p>In your physical wallet, you have $1s, $5s, $10s, etc. When you’re buying something, you use those bills as “inputs” for your transaction. </p><p>For example, if you want to buy a book for $10, you’d use a $10 bill as your input. Once you’ve purchased that book, you've spent your physical dollars. Now your $10 belongs to someone else - the resulting output of your transaction.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/Cash-example-UTXO-model.png" class="kg-image" alt="UTXO Consolidation Explained"><figcaption><em>Example: Sending $10 to someone else</em></figcaption></figure><p>But what if you don’t have the perfect inputs? </p><p>Let’s say you’re buying that same book for $10, but only have a $20 bill. In this case, you’d use your $20 as your input and instead create <em>two</em> outputs: $10 for the book seller and $10 as “<em>change</em>” for yourself.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/Cash-example-with-change-utxo-model.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/Cash-example-with-change-utxo-model.png 600w, https://bitcoinbriefly.com/content/images/2021/12/Cash-example-with-change-utxo-model.png 880w" sizes="(min-width: 720px) 720px"><figcaption><em>Example: Sending $10 to someone else, receiving $10 as change</em></figcaption></figure><p>With this analogy in mind, you can think of UTXOs as the following:</p><p><strong>A UTXO is to Bitcoin wallets, what cash is to analog wallets.</strong></p><p><strong>Each transaction consumes existing UTXOs and creates new ones.</strong> Your wallet will fund your transaction using your UTXOs as inputs and output new UTXOs. </p><p>In the cases where you don’t have the perfect amount of UTXOs for a transaction, you’ll receive a new UTXO back as <strong>change</strong>.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/bitcoin-utxo-example-with-change.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/bitcoin-utxo-example-with-change.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/bitcoin-utxo-example-with-change.png 1000w, https://bitcoinbriefly.com/content/images/2021/12/bitcoin-utxo-example-with-change.png 1170w" sizes="(min-width: 720px) 720px"><figcaption>Example: Sending 3 BTC to someone and receiving 0.03 BTC in change</figcaption></figure><p>So now that we understand UTXOs…</p><h2 id="what-s-the-issue-with-having-too-many-utxos">What’s the issue with having too many UTXOs?</h2><p>Imagine paying for a $100 item using only $1 bills. The vendor has a more burdensome task of counting all 100 $1 bills compared to just receiving one $100 bill right? </p><p>Bitcoin miners are similar. The more UTXOs you use as inputs for a transaction, the more burden miners have. As a result, Bitcoin miners will charge you more in transaction fees. Why?</p><p>There are many factors that affect your overall transaction fees. </p><p>As covered in other articles, the <a href="https://bitcoinbriefly.com/so-your-bitcoin-transaction-is-stuck/#other-techniques-to-reduce-transaction-fees-and-further-fee-optimization">fee rate</a> and <a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/#address-prefixes-1-legacy-3-nested-segwit-bc1-native-segwit-and-how-to-save-money-on-your-bitcoin-transaction-fees">address type</a> you use affect your transaction fees. Additionally, the <strong>number of inputs and outputs you use also impacts your overall fees. </strong></p><p>The more UTXOs you use as inputs, the larger the size of your transaction. The larger your transaction size, the more miners will charge you.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/more-utxos-more-inputs-bigger-transaction-size-larger-transaction-fees.png" class="kg-image" alt="UTXO Consolidation Explained"><figcaption><em>Using More UTXOs as Inputs Results in Larger Transaction Fees Paid to Miners</em></figcaption></figure><p><strong>If you want to reduce the transaction fee you pay to miners, you want to use as few inputs as possible</strong>. Carrying a lot of UTXOs in your wallet will make them more expensive to spend later on. </p><p>So it’s important to<strong> reduce the number of UTXOs you have, to reduce your future transaction fees</strong>.</p><p>Fortunately, there’s a strategy to help you cut down on the number of UTXOs you have…</p><h2 id="what-is-utxo-consolidation">What is UTXO Consolidation?</h2><p><strong><strong>UTXO consolidation </strong></strong>helps you save on future transaction fees. It consumes your existing UTXOs and creates one new UTXO to an address you own.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/utxo-consolidation-examples-1.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/utxo-consolidation-examples-1.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/utxo-consolidation-examples-1.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/12/utxo-consolidation-examples-1.png 1600w, https://bitcoinbriefly.com/content/images/2021/12/utxo-consolidation-examples-1.png 1720w" sizes="(min-width: 720px) 720px"><figcaption><em>Examples of UTXO Consolidation: one to the same address; another to a new address</em></figcaption></figure><p>Once you've consolidated your UTXOs, you've reduced the sizes of your future transactions. As a result, you've reduced your future mining fees.</p><p>It’s like going to a store and asking them to exchange a bunch of smaller coins (like 10,000 cents) for one larger bill (a $100). You only need to carry one bill and it’s less resource-intensive to spend in the future.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/10000-pennies-or-one-100-bill.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/10000-pennies-or-one-100-bill.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/10000-pennies-or-one-100-bill.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/12/10000-pennies-or-one-100-bill.png 1600w, https://bitcoinbriefly.com/content/images/2021/12/10000-pennies-or-one-100-bill.png 1790w" sizes="(min-width: 720px) 720px"><figcaption><em>Example: Is it easier to hold and spend 10,000 pennies or one $100 bill?</em></figcaption></figure><p>Similarly, <strong>you only need one UTXO to transact</strong>. Any extra UTXOs make your future mining fees unnecessarily more expensive.</p><p>You might’ve noticed that a consolidation transaction looks like any other transaction. </p><p>You might be wondering: why not combine UTXOs later at the point of sale itself? Why consolidate UTXOs upfront and incur an extra transaction fee? </p><p>There are a few benefits to consolidating UTXOs in advance like this:</p><h2 id="what-are-the-benefits-of-utxo-consolidation">What are the Benefits of UTXO Consolidation?</h2><p>In addition to the <strong>future fee savings</strong> mentioned above…</p><p>One benefit is that you get to <strong>choose when you consolidate.</strong> </p><p>You don’t want to be in a situation where you’re in a rush to spend unconsolidated UTXOs. If you’re pressed for time, you’ll likely pay high fee rates if there’s network congestion. You’ll also have to input many UTXOs to fund your transaction, resulting in a high transaction fee. </p><p>By consolidating UTXOs in advance, <strong>you control</strong> <strong>when</strong> <strong>you incur these costs</strong>.</p><p>You’ll still use many UTXOs as inputs, but if you <strong>consolidate at a low fee rate</strong> (ie. <a href="https://bitcoinbriefly.com/so-your-bitcoin-transaction-is-stuck/#other-techniques-to-reduce-transaction-fees-and-further-fee-optimization">1 sat/vbyte</a>), you can cut your inevitable costs. </p><p>Consolidating UTXOs can be painful in the short term, but relieves a potentially much bigger pain in the future. </p><p>UTXO consolidation also gives you an opportunity to <strong>update your addresses</strong>. For example, you can “roll over” your legacy addresses’ UTXOs to a new Native SegWit Bech32 address. </p><p>In effect, you’re killing two birds with one stone. You're consolidating UTXOs and updating your addresses.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/utxo-consolidation-example-bc1-address-update-5.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/utxo-consolidation-example-bc1-address-update-5.png 600w, https://bitcoinbriefly.com/content/images/2021/12/utxo-consolidation-example-bc1-address-update-5.png 647w"><figcaption><em>Example: Consolidating UTXOs from Native Segwit and Wrapped SegWit addresses into a new Native SegWit address</em></figcaption></figure><p>Finally, you <strong>reduce the entire Bitcoin network’s UTXO set</strong> by consolidating UTXOs. This makes it easier for anyone to run a full node. Reducing the UTXO set improves Bitcoin’s accessibility, decentralization, and security.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/statoshi-utxo-set-5-years.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/statoshi-utxo-set-5-years.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/statoshi-utxo-set-5-years.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/12/statoshi-utxo-set-5-years.png 1600w, https://bitcoinbriefly.com/content/images/size/w2400/2021/12/statoshi-utxo-set-5-years.png 2400w" sizes="(min-width: 720px) 720px"><figcaption><em>The Bitcoin Network’s Complete UTXO Set - a spike in 2017 with continued growth to ATHs this in 2021 (statoshi.info - unspent transaction output set </em><a href="https://statoshi.info:3000/d/000000009/unspent-transaction-output-set?viewPanel=6&amp;orgId=1&amp;from=now-5y&amp;to=now&amp;refresh=10m"><em>https://statoshi.info:3000/d/000000009/unspent-transaction-output-set?viewPanel=6&amp;orgId=1&amp;from=now-5y&amp;to=now&amp;refresh=10m</em></a><em>)</em></figcaption></figure><p>All this is rosy, but there have to be tradeoffs right?</p><h2 id="what-are-the-disadvantages-of-utxo-consolidation">What are the Disadvantages of UTXO Consolidation?</h2><p>Well, you <strong>still have to pay a transaction fee</strong> to consolidate your existing UTXOs. </p><p>But the primary disadvantage of UTXO consolidation is that it’s <strong>harmful to privacy</strong>. Why? </p><p>You're <strong>connecting previously-unrelated addresses and UTXOs</strong>. It lets others know that these inputs are all controlled by the same entity. </p><p>Now an outside observer can track your previous UTXO addresses and histories. They can also track your future transactions.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh5.googleusercontent.com/rWpfZt1ZsedtRqtkjFiURqgjDpyEDeZcM5IvScf5lOSeB-yKbv8U-CUySzClMOuEK7GrP67Fd-ThlRz9cshSmfPUbz7AMT5dyx2FT_1Q33CDxIxT0m9DBLeHgWvohYvD1P4eoip4" class="kg-image" alt="UTXO Consolidation Explained"><figcaption>Example: <em>Chainalysis diagram </em><a href="https://twitter.com/chainalysis/status/1289355514564861954?s=20"><em>https://twitter.com/chainalysis/status/1289355514564861954?s=20</em></a></figcaption></figure><p>Yet, this <strong>privacy issue isn’t as important for public entities</strong>. </p><p>For example, if a charity uses one static donation address, its UTXOs are available for all to see. In this case, UTXO consolidation would not leak any new information to an outsider. </p><p>This leads us to the question…</p><h2 id="who-is-utxo-consolidation-useful-for">Who is UTXO Consolidation Useful For?</h2><p>UTXO consolidation makes sense for entities who have many UTXOs. Like exchanges or merchants who receive many transactions.  </p><p>It also makes sense for those who use static public addresses. </p><p>Finally, individuals who prefer fee savings over privacy might find UTXO consolidation helpful.</p><p>So if you’re interested in consolidating UTXOs…</p><h2 id="how-do-i-consolidate-utxos">How do I Consolidate UTXOs?</h2><p>You can simply send your max balance to an address you own.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/automatic-coin-selection-bitcoin-design.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/automatic-coin-selection-bitcoin-design.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/automatic-coin-selection-bitcoin-design.png 1000w, https://bitcoinbriefly.com/content/images/2021/12/automatic-coin-selection-bitcoin-design.png 1150w" sizes="(min-width: 720px) 720px"><figcaption><em>Automatic Coin Selection by </em><a href="https://bitcoin.design/guide/payments/send/coin-selection/"><em>https://bitcoin.design/guide/payments/send/coin-selection/</em></a></figcaption></figure><p>If your wallet offers “coin control,” you can manually select which UTXOs you’d like to consolidate.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/manual-coin-selection-bitcoin-design.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/manual-coin-selection-bitcoin-design.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/manual-coin-selection-bitcoin-design.png 1000w, https://bitcoinbriefly.com/content/images/2021/12/manual-coin-selection-bitcoin-design.png 1130w" sizes="(min-width: 720px) 720px"><figcaption><em>Manual Coin Selection by </em><a href="https://bitcoin.design/guide/payments/send/coin-selection/"><em>https://bitcoin.design/guide/payments/send/coin-selection/</em></a></figcaption></figure><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/fd6VzcJ5IisXfuSt_P1B0xbSO6jvWKojFdctCt45sziCxiZmBUSnI2Ppif03pmpt8XuykBquUCt60QICM5nUb34_ZuwdtJkvFhsbYRt6QB39vHAvfgxfH4NaN7t4SRJbqSGPLUD5" class="kg-image" alt="UTXO Consolidation Explained"><figcaption><em>Coin Control in Electrum Wallet </em><a href="https://bitcoinelectrum.com/how-to-spend-specific-utxos-in-electrum/"><em>https://bitcoinelectrum.com/how-to-spend-specific-utxos-in-electrum/</em></a></figcaption></figure><h2 id="what-is-utxo-batching">What is UTXO Batching?</h2><p>Using many UTXOs as inputs or outputs increases a transaction’s size and respective fees. </p><p><strong>UTXO batching</strong> creates many UTXO outputs to a variety of receivers in one transaction. By batching UTXOs, you reduce the number of change outputs you would've otherwise created. So batching helps you save on future fees too. </p><p>In other words, batching is to outputs what consolidation is to inputs.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/batching-utxos-example.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/batching-utxos-example.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/batching-utxos-example.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/12/batching-utxos-example.png 1600w, https://bitcoinbriefly.com/content/images/2021/12/batching-utxos-example.png 1690w" sizes="(min-width: 720px) 720px"><figcaption>Example: Batching UTXOs</figcaption></figure><p>Batching is very useful for entities that transact often. For example, employers can batch UTXOs when processing payroll payments to employees. </p><p>Exchanges often batch UTXOs when sending out “withdrawal” payments to their customers.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/12/exchange-batching-transaction-example.png" class="kg-image" alt="UTXO Consolidation Explained" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/12/exchange-batching-transaction-example.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/12/exchange-batching-transaction-example.png 1000w, https://bitcoinbriefly.com/content/images/2021/12/exchange-batching-transaction-example.png 1140w" sizes="(min-width: 720px) 720px"><figcaption>Real Example: 152 outputs in a batching transaction <a href="https://mempool.space/tx/6be9f2847cee23e2e6bd5543e50a3ca8245b7dc2165db9eb7d75af7c8f76713d">https://mempool.space/tx/6be9f2847cee23e2e6bd5543e50a3ca8245b7dc2165db9eb7d75af7c8f76713d</a></figcaption></figure><h2 id="what-is-utxo-management">What is UTXO Management?</h2><p>UTXO management is a topic outside the scope of this article. </p><p>But if you’re interested in using your UTXOs in the most cost-effective and privacy-preserving way, check out the following topics: <strong>labeling, coin control, and change avoidance.</strong></p><h2 id="conclusion">Conclusion</h2><p>In summary: </p><ol><li>UTXOs are to bitcoin wallets, what physical bills are to analog wallets.</li><li>You use UTXOs as inputs to transactions, which increases the size of your transaction.</li><li>The larger your transaction size, the more fees you must pay to miners.</li><li>To reduce your future fees, you can consolidate UTXOs.</li><li>You consolidate UTXOs by sending a new transaction to yourself at a low fee rate.</li><li>Consider your privacy before consolidating UTXOs.</li><li>You can also batch UTXOs if you’re looking to pay many recipients.</li><li>UTXO management and coin control is for advanced users, but worth digging into.</li></ol><p>If you found this article helpful, let me know on <a href="https://twitter.com/itsminawhile">Twitter</a>! </p><p>And don't forget to subscribe to the mailing list below:</p><!--kg-card-begin: html--><iframe src="https://bitcoinbriefly.substack.com/embed" width="480" height="320" style="border:1px solid #EEE; background:white;" frameborder="0" scrolling="no"></iframe><!--kg-card-end: html--><hr><p><em>Notes</em></p><ul><li><em>Some addresses and transactions in the examples above are fictional to demonstrate concepts.</em></li><li><em>When you use UTXOs as inputs, you remove UTXOs from the UTXO set. You also output new UTXOs, adding to the UTXO set. In other words, UTXOs can only be used to fund new transactions as inputs. This helps prevent double-spending and fraud. </em></li><li><em>You can sum up the network's complete UTXO set to calculate the total circulating supply of bitcoin. This independent verification of the money supply is unique to Bitcoin. Try doing this with the USD money supply ;)</em></li><li><em>Each input adds 41 or more vbytes to a transaction. Usually 69 vbytes.</em></li><li><em>Maintaining a lot of UTXOs is not only bad for you. It’s also bad for the entire Bitcoin network: all Bitcoin nodes must manage and maintain the entire UTXO set. A bigger UTXO set requires more computational resources from each node.</em></li><li><em>You can't consolidate an unlimited number of UTXOs in a single transaction. You must conform to the dimensions of the block size.</em></li><li><em>Don't consolidate all your UTXOs if you need to spend BTC while you're waiting for confirmations. And only consolidate UTXOs that have already been confirmed.</em></li><li><em>Batching is sometimes called a “Distributing Transaction”</em></li></ul>]]></content:encoded></item><item><title><![CDATA[How to Use Mempool.Space]]></title><description><![CDATA[Learn how to use Mempool.space - a blockchain and mempool explorer]]></description><link>https://bitcoinbriefly.com/how-to-use-mempool-space-block-explorer/</link><guid isPermaLink="false">601c6d3dbfd4f304cfadd41a</guid><category><![CDATA[Walkthroughs]]></category><dc:creator><![CDATA[Alex Min]]></dc:creator><pubDate>Fri, 05 Feb 2021 12:41:12 GMT</pubDate><media:content url="https://bitcoinbriefly.com/content/images/2021/04/unconfirmed-confirmed-blocks-mempool-space-bitcoin-briefly-1.png" medium="image"/><content:encoded><![CDATA[<img src="https://bitcoinbriefly.com/content/images/2021/04/unconfirmed-confirmed-blocks-mempool-space-bitcoin-briefly-1.png" alt="How to Use Mempool.Space"><p>Published: 2021-02-05 at block 669,215<br>Bitcoin Price: $38,100</p><p><strong><a href="https://mempool.space/">Mempool.space</a> is a Bitcoin block explorer and mempool explorer.</strong></p><p>A <strong>block explorer</strong> (blockchain explorer) allows you to browse through all Bitcoin transactions. It’s useful for seeing address history, transaction status, etc.  </p><p>A <strong>mempool </strong>(short for memory pool) stores unconfirmed transactions in a "waiting room" inside of a Bitcoin node. </p><p>A <strong>mempool explorer</strong> allows you to see the state of a mempool and its pending transactions. It’s useful for estimating fee rates and getting ETAs on unconfirmed transactions.</p><p>In this blog post, I’ll walk you through how to use Mempool.space. </p><p>Note: If you're looking to speed up your unconfirmed bitcoin transaction, then you might find this <a href="https://bitcoinbriefly.com/so-your-bitcoin-transaction-is-stuck/">explainer on confirming stuck transactions</a> helpful.  </p><p>First let’s focus on the unconfirmed and confirmed blocks at the top of the page:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/unconfirmed-confirmed-blocks-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/unconfirmed-confirmed-blocks-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/unconfirmed-confirmed-blocks-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/unconfirmed-confirmed-blocks-mempool-space-bitcoin-briefly.png 1600w, https://bitcoinbriefly.com/content/images/size/w2400/2021/04/unconfirmed-confirmed-blocks-mempool-space-bitcoin-briefly.png 2400w" sizes="(min-width: 720px) 720px"></figure><p>On the left side, you’ll see a queue of <strong>unconfirmed</strong> blocks:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/unconfirmed-blocks-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/unconfirmed-blocks-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/unconfirmed-blocks-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/unconfirmed-blocks-mempool-space-bitcoin-briefly.png 1347w" sizes="(min-width: 720px) 720px"></figure><p>The block that’s closest to the line is the <strong>next one to be confirmed</strong>:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/next-unconfirmed-block-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/next-unconfirmed-block-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/next-unconfirmed-block-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/next-unconfirmed-block-mempool-space-bitcoin-briefly.png 1326w" sizes="(min-width: 720px) 720px"></figure><p>Let’s break down its details:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/next-unconfirmed-block-details-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>Hold on a sec... did you notice anything different between this block and the one enclosed in red before it? If you compare the two, you’ll notice slight differences between them. This is because I took the screenshots a few minutes apart: </p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/difference-in-unconfirmed-blocks-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/difference-in-unconfirmed-blocks-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/2021/04/difference-in-unconfirmed-blocks-mempool-space-bitcoin-briefly.png 951w" sizes="(min-width: 720px) 720px"></figure><p>Why am I spending time highlighting this? </p><p>Because the contents of this unconfirmed block changed dramatically. <strong>Miners reprioritized certain transactions over others within this short time frame.</strong></p><p>Miners must prioritize transactions because each block can only fit so many. If demand for block space is high, miners will focus on transactions with higher fee rates (though other factors like the age of the transaction and its size are also considered). </p><p>The higher your transaction's relative fee rate, the more likely miners will process your transaction ASAP. </p><p>Ok so now we understand why the figures in the same block changed. Now let’s break down what each of the figures within the block mean:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/next-unconfirmed-block-details-mempool-space-bitcoin-briefly-1.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>On the bottom, you’ll see <strong>“In ~10 minutes”. </strong></p><p><strong>It's an ETA</strong>. This means that we expect miners to confirm this upcoming block in 10 minutes, as expected. But this is an estimate - some blocks can take 1 second to mine, others can take hours… but on average, 10 minutes.</p><p>Mining confirmation times and <a href="https://en.bitcoin.it/wiki/Difficulty">difficulty</a> adjustment / targeting is outside the scope of this blog post, but I’d recommend researching the topics. It will help you understand how the Bitcoin network processes transactions.</p><p>On top, you’ll see <strong>~68 sat/vB.</strong></p><p>This refers to the <strong>median fee rate</strong> paid by each transaction in that block. Again, the higher the relative fee rate a transaction has over others, the more likely a miner is to prioritize that transaction. </p><p>What are sat/vB? </p><p>You may have heard of terms like satoshis per byte, or satoshis per virtual byte. These are two ways of describing the same thing. They refer to the fee rate that a transaction is willing to pay miners to get confirmed. </p><p>In the numerator are satoshis (or sats for short).</p><p>The smallest denomination of a bitcoin is a satoshi (like cents in a dollar). 100,000,000 satoshis = 1 bitcoin. </p><p>So in the example above, the median fee rate is 68 satoshis (or 0.00000068 BTC) per virtual byte. </p><p>What are virtual bytes? </p><p>We know that a block has a limited amount of space and transactions are data that fill up that space, right?</p><p>Well, block space used to be measured and limited to their “blocksize” of 1 MB or 1,000,000 bytes. </p><p>But since 2017, we now measure and limit blocks to their “blockweight” of 4,000,000 weight units (WU). If you’re interested in learning more, you may want to research Segregated Witness (SegWit). </p><p>We use "virtual bytes" to convert weight units back to bytes by dividing by 4. </p><p>Ok so putting this fee rate concept (sats/vBytes) back into context…</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/fee-rate-unconfirmed-block-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>Initially, the upcoming block was <strong>1.18 MB in size</strong> <strong>with</strong> <strong>2,886 pending transactions</strong>. </p><p>This means that the average size of each transaction was 409 virtual bytes. (1,180,000 virtual bytes / 2886 transactions).</p><p>We can get the median fee of each transaction by multiplying the average size by the median fee rate. In this case:</p><ul><li>Median fee rate = 15 sat/vB</li><li>Average size = 409 vB</li><li>Median fee = 15 sat/vB * 409 vB = 6135 sats or 0.00006135 BTC</li></ul><p>Each transaction in this unconfirmed block was willing to pay 0.00006135 BTC in mining fees. At a $36k price point, this comes out to ~$2.20. </p><p><strong>But suddenly, more unconfirmed transactions flooded the mempool with more competitive fee rates. Miners then reprioritized transactions with an median fee rate of ~68 sat/vB:</strong></p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/next-unconfirmed-block-details-mempool-space-bitcoin-briefly-2.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>During this reshuffling, the block’s virtual size grew to 1.31 MB and the number of unconfirmed transactions fell to 2,555. </p><p>After running the same calculations, how much do you think each pending transaction in this same unconfirmed block was willing to pay? On average (median), 0.00034864 BTC in mining fees or about $12.55 at 1 BTC = $36,000. </p><p><strong>If you’ve ever wondered why <a href="https://bitcoinbriefly.com/so-your-bitcoin-transaction-is-stuck/">your bitcoin transaction got stuck</a> in the past, it’s because of these dynamics. </strong>Miners prioritized more competitive transactions over yours in the fee rate market. </p><p>Finally, the <strong>14 - 866 sat/vB figure refers to the range of fee rates </strong>included in this unconfirmed block, instead of the median.<strong> </strong></p><p>Cool, so now you understand the unconfirmed blocks section. Let’s zoom back out and focus on the <strong>confirmed</strong> blocks on the right side:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/confirmed-blocks-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/confirmed-blocks-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/confirmed-blocks-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/confirmed-blocks-mempool-space-bitcoin-briefly.png 1297w" sizes="(min-width: 720px) 720px"></figure><p>From left to right, it reads from the most recently-confirmed block to older ones. </p><p>The higher the block height (eg. 667,306), the more recent the confirmation. The left-most block 667,306 received one confirmation, whereas block 667,301 has 6 confirmations. </p><p>Now let’s look at a confirmed block:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/confirmed-block-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>It’s really similar. The only difference is that instead of showing an ETA, it shows when the block was mined (12 minutes ago). It also assigns the block a formal block number (aka. Its block height).</p><p>Got it so far? </p><p>Great. So let’s imagine you’re about to send a transaction. You check the mempool and see something like this:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/fee-rate-recommendation-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/fee-rate-recommendation-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/2021/04/fee-rate-recommendation-mempool-space-bitcoin-briefly.png 657w"></figure><p>How high of a fee rate would you set in order to get confirmed in the next block?</p><p>Well the upcoming block is showing an median fee rate of 14 sat/vB. You can also see Mempool.space’s suggestions: the low, medium, and high fee rates. </p><p>But as demonstrated before, a 15 sat/vB estimate was quickly eclipsed by a 68 sat/vB median. </p><p><strong>So these estimations can help you get your bearings. But you shouldn’t rely on these estimates when customizing your transaction fee rate.</strong></p><p>How can you get a better estimate? Let’s look at these charts:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/mempool-incoming-transactions-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/mempool-incoming-transactions-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/mempool-incoming-transactions-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/mempool-incoming-transactions-mempool-space-bitcoin-briefly.png 1121w" sizes="(min-width: 720px) 720px"></figure><p>And let’s focus on the left side first:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/purging-memory-usage-unconfirmed-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>What’s “Purging” mean? </p><p>It means that the mempool is so full that transactions with fee rates under 1.2 sat/vB are being ignored. These 1.2 sat/vB transactions are so uncompetitive that they’re getting dropped from the mempool.</p><p>“Memory usage” is exactly like it sounds like. </p><p>Transactions take up space. Each full node can fit 300 MB worth of unconfirmed transactions in their mempool storage by default. Assuming that each transaction is about 500 bytes, then a node’s 300 MB mempool holds about 600,000 unconfirmed transactions.</p><p>In the example above, the mempool is 327 MB big with 48,477 “unconfirmed” TXs (aka. TXNs, transactions). This means that on average, each unconfirmed transaction in the 327 MB mempool is about 6,745 bytes big. </p><p>But these 3 metrics (purging, memory usage, unconfirmed) don’t really help us optimize our fee rate. Even the estimates are showing 14 sat/vB. </p><p><strong>This is where learning how to read the mempool evolves beyond just a science - it’s also an art.</strong></p><p>Look at the chart below the 3 metrics - there are these different colored layers:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/purging-memory-usage-unconfirmed-mempool-space-bitcoin-briefly-1.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p><strong>The chart itself represents the current mempool. The colored layers represent transaction fee rates. </strong></p><p>You can click on this icon in the navigation bar to see the exact fee rate legend: </p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/navigate-mempool-legend-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/navigate-mempool-legend-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/navigate-mempool-legend-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/navigate-mempool-legend-mempool-space-bitcoin-briefly.png 1600w, https://bitcoinbriefly.com/content/images/2021/04/navigate-mempool-legend-mempool-space-bitcoin-briefly.png 1963w" sizes="(min-width: 720px) 720px"></figure><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/mempool-graph-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/mempool-graph-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/mempool-graph-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/mempool-graph-mempool-space-bitcoin-briefly.png 1600w, https://bitcoinbriefly.com/content/images/size/w2400/2021/04/mempool-graph-mempool-space-bitcoin-briefly.png 2400w" sizes="(min-width: 720px) 720px"></figure><p>As you can see, the pink on the bottom represents unconfirmed transactions in the mempool with a 1 sat/vB fee rate. </p><p>In the layer above that, you see unconfirmed transactions with a 1 - 2 sat/vB fee rate. The layer above that, 2 - 3 sat/vB. And so on and so forth.</p><p>At the top you can see some yellow, representing 20 - 30 sat/vByte. And above that yellow, there are some spots of dark red representing transactions with up to 90 - 100 sat/vB fee rates. Further beyond that, there is probably a layer that goes all the way up to 690 sat/vB, as shown in the range earlier:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/fee-rate-unconfirmed-block-mempool-space-bitcoin-briefly-1.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>You can also toggle different views. The above image shows a 2 hour view of the mempool. The image below shows a 1-month view of the mempool:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/one-month-view-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/one-month-view-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/one-month-view-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/one-month-view-mempool-space-bitcoin-briefly.png 1600w, https://bitcoinbriefly.com/content/images/size/w2400/2021/04/one-month-view-mempool-space-bitcoin-briefly.png 2400w" sizes="(min-width: 720px) 720px"></figure><p>You can see that on January 1st (01/01), the mempool almost fully cleared. Most transactions were able to confirm with a 1 sat/vB fee rate. </p><p>Then more unconfirmed transactions began to fill the mempool from the 9th of January (09/01). The demand for block space increased, likely from more speculative trading activity. This made 1 sat/vB fee rates (pink) less viable than more competitive 10 - 40 sat/vB fee rates (green, yellow). </p><p>So you can likely get away with a 1 sat/vB fee rate if you have the patience for it and if 1 sat/vB transactions aren't being purged. But <strong>if you’re trying to get your transaction confirmed ASAP, then you’ll need to pay a higher fee rate.</strong></p><p>There’s one more metric we can look at to better estimate the ideal fee rate:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/incoming-transactions-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p><strong>“Incoming transactions”</strong> shows the amount of unconfirmed transactions entering the mempool, measured in vBytes per second (vB/s). </p><p>So around 8:15 in this chart, you can see there was a sudden influx of unconfirmed transactions entering the mempool, around ~6,500 vB/s. </p><p>If we assume that each transaction is on average ~500 bytes, then the meter above tells us there are ~3 incoming transactions every second. </p><p>Now that we’re armed with all this data… let’s bring it back. In this scenario, what fee rate would you set to get mined ASAP? Let me know in the comments below. </p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/fee-recommendation-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/fee-recommendation-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/2021/04/fee-recommendation-mempool-space-bitcoin-briefly.png 657w"></figure><p>I’d probably set a fee rate of 15 - 20 sat/vB to get confirmed in the next block. </p><p>Cool - so now we understand the different <strong>mempool explorer</strong> components.</p><p>Now let’s dive into the <strong>block explorer</strong> components:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/block-explorer-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/block-explorer-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/block-explorer-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/block-explorer-mempool-space-bitcoin-briefly.png 1126w" sizes="(min-width: 720px) 720px"></figure><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/latest-blocks-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>Here, you’ll see a list of the latest blocks that have been mined. It's listed from most recently mined at the top, to less recently mined as you go down. </p><p>These correlate to the blocks you see on the top of the page:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/latest-blocks-recently-confirmed-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/latest-blocks-recently-confirmed-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/latest-blocks-recently-confirmed-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/latest-blocks-recently-confirmed-mempool-space-bitcoin-briefly.png 1284w" sizes="(min-width: 720px) 720px"></figure><p>Let’s click on a block: </p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/latest-block-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>Here’s what we see:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/block-details-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/block-details-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/block-details-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/block-details-mempool-space-bitcoin-briefly.png 1297w" sizes="(min-width: 720px) 720px"></figure><p>In block <a href="https://mempool.space/block/00000000000000000003893f55e0e8568fe8ccfe3ec3db9f595693c5b7c83bfa">667,306</a>, we can see that</p><ul><li>It was first mined at 2021-01-23 08:47 (aka. Timestamp)</li><li>Its size was 1.39 MB</li><li>Its weight was 3.99 MWU (mega weight units)</li><li>The total fees generated from the transactions in this block was 0.43 BTC (43,000,000 satoshis).</li><li>The block subsidy was 6.25 BTC (as is expected for this <a href="https://bitcoinbriefly.com/21-million-bitcoin/">reward era</a>)</li><li>The miner who found the block was SpiderPool</li><li>From 2,074 transactions (2,075 minus the <a href="https://www.javatpoint.com/coinbase-transaction#:~:text=A%20coinbase%20transaction%20is%20the,also%20sent%20in%20this%20transaction.">coinbase reward transaction</a>), each transaction paid a median fee of 20,732 sats</li></ul><p>Now let’s focus on the transactions themselves. Let’s click on the second transaction in that block:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/transaction-details-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/transaction-details-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/transaction-details-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/transaction-details-mempool-space-bitcoin-briefly.png 1146w" sizes="(min-width: 720px) 720px"></figure><p>Here’s a transaction whose transaction ID (TXID) is <a href="https://mempool.space/tx/71a37623a25d8c8b2c2517f90cbc9ab1e9c27d189da60d9dc054bcda36b89410">71a37623a25d8c8b2c2517f90cbc9ab1e9c27d189da60d9dc054bcda36b89410</a></p><ul><li>It received 10 confirmations (as it was included and mined in block 667,306) and paid a total of 68,232 satoshis in transaction fees at a <strong>623.1 sat/vB fee rate!</strong></li><li>If 1 BTC = $36k, they paid $24.56 in total txn fees to send ‎0.00009996 BTC (the "output", which is about ~$3.69)... <strong>this is what happens when you don’t know how to read the mempool and customize transaction fee rates!</strong></li><li>It sent bitcoin from a <a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/#address-prefixes-1-legacy-3-nested-segwit-bc1-native-segwit-and-how-to-save-money-on-your-bitcoin-transaction-fees">“bc1” address</a> so it’s noted as a SegWit transaction. </li><li>But the transaction did not opt-into <a href="https://bitcoinbriefly.com/so-your-bitcoin-transaction-is-stuck/#what-does-an-rbf-transaction-look-like">Replace by Fee (RBF)</a>. So if the transaction’s fee rate was deprioritized by miners, the sender wouldn’t be able to replace this transaction with a new competitive one with a higher fee. The sender would need to wait for his transaction to get mined or dropped from the mempool. </li><li>Below in the Details, you can see the transaction’s size, virtual size, and weight</li></ul><p>Got it?</p><p>So then this should be easy to understand:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/latest-transactions-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>It’s just a list of the latest transactions joining the mempool. These transactions are unconfirmed - you can tell by clicking on the TXID:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/latest-unconfirmed-transaction-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/latest-unconfirmed-transaction-details-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/latest-unconfirmed-transaction-details-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/latest-unconfirmed-transaction-details-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/latest-unconfirmed-transaction-details-mempool-space-bitcoin-briefly.png 1294w" sizes="(min-width: 720px) 720px"><figcaption>Unconfirmed transaction</figcaption></figure><p>If you’re looking for a specific transaction, address, or block, you can use the search feature on the top right:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/search-function-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/search-function-mempool-space-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/search-function-mempool-space-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/search-function-mempool-space-bitcoin-briefly.png 1600w, https://bitcoinbriefly.com/content/images/size/w2400/2021/04/search-function-mempool-space-bitcoin-briefly.png 2400w" sizes="(min-width: 720px) 720px"></figure><p>But if you're privacy conscious, you should host your own block explorer. Also consider connecting to a block explorer using Tor. </p><p>Why? Because if you're typing unique addresses into an online service, they can map that to your device.</p><p>If you'd like a tutorial on hosting your own block explorer, let me know in the comments below.</p><p>Ok. There’s one thing I haven’t yet covered and it’s the <strong>difficulty adjustment</strong>:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/difficulty-adjustment-mempool-space-bitcoin-briefly.png" class="kg-image" alt="How to Use Mempool.Space"></figure><p>This is Mempool.space’s prediction for how the network difficulty will increase or decrease based on the existing mining power. </p><p>If it shows a negative %, that means that miners are having a difficult time producing blocks every 10 minutes, so the difficulty will likely adjust downwards to make hitting that 10 minute target more feasible.</p><p>If it shows a positive %, that means that miners are easily producing blocks every 10 minutes or less, so the difficulty will likely adjust upwards to make it more difficult to mine bitcoin. </p><p>Again, explaining “Difficulty” is outside the scope for this blog post. If you’d like a detailed explanation of difficulty, let me know in the comments below.</p><p>So congrats! You’re now an expert on mempools and block explorers. Knowing how to use these tools is critical within the world of Bitcoin. </p><p><strong>Now… before you send a transaction, you can look at the mempool to customize your fee rate accordingly. Once you’ve sent your transaction, you can see its status using a tool like Mempool.Space.</strong> </p><p>Hope this was helpful! If so, let me know what you've learned in the comments below, and feel free to share this post with other beginners who might also be struggling with these concepts! </p><p>You’re well on your way to becoming an expert Bitcoiner.</p><p>What did I miss? What else would you like to learn more about? <a href="https://twitter.com/bitcoin_briefly">Let me know on Twitter</a>!</p><!--kg-card-begin: html--><iframe src="https://bitcoinbriefly.substack.com/embed" width="480" height="320" style="border:1px solid #EEE; background:white;" frameborder="0" scrolling="no"></iframe><!--kg-card-end: html-->]]></content:encoded></item><item><title><![CDATA[The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses]]></title><description><![CDATA[The terminology around wallets can be complex. Private keys, seeds, public keys, addresses, HD wallets, BIPs... 

Stick with me and by the end of the blog post, you'll have a strong understanding of the concepts above. ]]></description><link>https://bitcoinbriefly.com/ultimate-guide-to-bitcoin-wallets-seeds-private-keys-public-keys-and-addresses/</link><guid isPermaLink="false">600609858476b84d44a8a802</guid><category><![CDATA[Explainers]]></category><dc:creator><![CDATA[Alex Min]]></dc:creator><pubDate>Wed, 20 Jan 2021 00:49:00 GMT</pubDate><media:content url="https://bitcoinbriefly.com/content/images/2021/04/matt-artz-py_azjfdbhq-unsplash_optimized.jpg" medium="image"/><content:encoded><![CDATA[<img src="https://bitcoinbriefly.com/content/images/2021/04/matt-artz-py_azjfdbhq-unsplash_optimized.jpg" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses"><p>Published: 2021-01-19 at block 666,827<br>Bitcoin Price: $36,340</p><h2 id="introduction">Introduction</h2><p>So you finally bought some bitcoin and started learning about wallets. </p><p>But all the terminology and technical details are overwhelming. Private keys, seeds, public keys, addresses, HD wallets, BIPs... All these concepts seem pretty foreign right?</p><p>Stick with me and by the end of the blog post, you'll have a strong understanding of the concepts above. </p><h2 id="table-of-contents">Table of Contents</h2><!--kg-card-begin: html--><ul>
    <li><a href="#introduction">Introduction</a></li>
    <li><a href="#what-is-a-private-key">What is a Private Key?</a></li>
    <li><a href="#what-is-a-seed-phrase">What is a Seed Phrase?</a></li>
    <li><a href="#where-can-i-find-my-seed-phrase">Where can I find my seed phrase?</a></li>
    <li><a href="#how-should-i-backup-my-seed-phrase">How should I backup my seed phrase?</a></li>
    <li><a href="#where-can-i-use-my-seed-phrase">Where can I use my seed phrase?</a></li>
    <li><a href="#what-is-bip39">What is BIP39?</a></li>
    <li><a href="#how-do-i-import-my-seed-phrase">How do I import my seed phrase?</a></li>
    <li><a href="#what-is-a-public-key">What is a Public key?</a></li>
    <li><a href="#what-is-an-address">What is an Address?</a></li>
    <li><a href="#why-does-my-bitcoin-address-change">Why does my Bitcoin Address Change?</a></li>
    <li><a href="#what-is-a-bip32-hierarchical-deterministic-hd-wallet">What is a BIP32 Hierarchical Deterministic (HD) Wallet?</a></li>
    <li><a href="#what-is-a-wallet">What is a Wallet?</a></li>
    <li><a href="#conclusion">Conclusion</a></li>
</ul><!--kg-card-end: html--><h2 id="what-is-a-private-key">What is a Private Key?</h2><p>A private key is like an ATM PIN to your bank account. A bank account has a unique PIN. A PIN proves to the ATM that you own the account and allows you to spend the funds in the account, right? </p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/photo-1601597111158-2fceff292cdc_optimized-1.jpeg" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/photo-1601597111158-2fceff292cdc_optimized-1.jpeg 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/photo-1601597111158-2fceff292cdc_optimized-1.jpeg 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/photo-1601597111158-2fceff292cdc_optimized-1.jpeg 1600w, https://bitcoinbriefly.com/content/images/2021/04/photo-1601597111158-2fceff292cdc_optimized-1.jpeg 2000w" sizes="(min-width: 720px) 720px"><figcaption>Photo by <a href="https://unsplash.com/@eduschadesoares?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Eduardo Soares</a> / <a href="https://unsplash.com/?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Unsplash</a></figcaption></figure><p>Similarly, <strong>your private key proves to the Bitcoin network that you own bitcoin and allows you to spend your bitcoin.</strong></p><p>A private key is essentially a random number between 0 and 115,792,089,237,316,195,423,570,985,008,687,907,853,269,984,665,640,564,039,457,584,007,913,129,639,936. Pretty much, a 256-bit number. </p><p>But it'd be difficult to enter in a PIN like that every time you wanted to spend bitcoin, right? </p><p>So developers created a <strong>human-readable format</strong> to derive private keys: the popular <strong>seed phrase </strong>format.</p><h2 id="what-is-a-seed-phrase">What is a Seed Phrase?</h2><p>FYI: you might've heard "seed phrase" synonyms and variants like:</p><ul><li>Mnemonic phrase</li><li>Mnemonic code words</li><li>Mnemonic seed</li><li>Seed words</li><li>Backup seed</li><li>Recovery phrase</li><li>BIP39 seed phrase</li></ul><p>These are all interchangeable. Regardless, a seed phrase is simply <strong>a representation of a random number. It's an ordered sequence of 12 or 24 words</strong>, chosen from a <a href="https://github.com/bitcoin/bips/blob/master/bip-0039/english.txt">list of 2048 words</a>. Using cryptography, <strong>your wallet can derive your private key using your seed phrase</strong>. And with that private key, your wallet can spend your bitcoin. </p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/seed-phrase-to-private-key-derivation-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses"><figcaption>Private Key Derivation by Bitcoin Briefly</figcaption></figure><p>Each seed phrase is unique. The chances that you share the same seed phrase with someone else are virtually zero. And just as improbable is brute-forcing a seed phrase with a non-zero bitcoin balance. </p><p>Here's an example of a seed phrase:</p><!--kg-card-begin: markdown--><p><code>dove lumber quote board young robust kit invite plastic regular skull history</code></p>
<!--kg-card-end: markdown--><h2 id="where-can-i-find-my-seed-phrase">Where can I find my seed phrase? </h2><p>You might be wondering where you can find your seed phrase. <strong>Usually, you're required to backup a copy of your seed phrase when you first set up your wallet. </strong></p><p>But in case you haven't, <strong>some wallets offer a way to find or export your seed phrase. </strong></p><p>Before you go looking, make sure to keep your seed phrase away from prying eyes. <strong>Anyone with your seed phrase can steal your bitcoin!</strong> </p><p>Like an ATM PIN, it's important to keep your seed phrase secret. <strong>NEVER share your seed phrase</strong> with anyone you don't trust (like I did in the example above)! </p><p>If you share your seed phrase with anyone, they can control and spend your bitcoin. They can steal your funds and you'll have no way to get them back - Bitcoin transactions are irreversible. </p><p>So whenever someone asks for your seed phrase or for you to send funds, it should ring alarm bells in your head.</p><p>There are <a href="https://www.blockstreamscamdb.com/">many scammers</a> who will try to get you to share your seed phrase. They're usually get-rich-quick schemes. But there are also sophisticated phishing schemes. They look like legit websites, emails, developer tools, recovery kits, etc.</p><p>Beware: </p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/04/seed-phrase-caution-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/seed-phrase-caution-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/2021/04/seed-phrase-caution-bitcoin-briefly.png 970w" sizes="(min-width: 720px) 720px"></figure><p>If the scam is on a website, make sure to check that the URL is correct. And as always, feel free to <a href="https://subredditstats.com/r/bitcoinbeginners">ask Reddit</a> whether something is a scam.</p><p>Ok so... are you away from prying eyes in a safe, secure, and private location? Good. </p><!--kg-card-begin: html--><p>If you already know how to find your seed phrase, then feel free to <a href="#how-should-i-backup-my-seed-phrase">skip ahead to the next section</a>.</p><!--kg-card-end: html--><p>If not, I've added how to find your seed phrase in the following wallets for your convenience. Let me know if I missed any examples in the comments below. </p><p>Note: you CANNOT view your seed phrase in Ledger or Trezor after your initial setup. </p><ul><li>How to find your seed phrase on <a href="https://coldcardwallet.com/docs/advanced">Coldcard</a>: Advanced &gt; Danger Zone &gt; View Seed Words</li><li>How to find your seed phrase on <a href="https://help.blockstream.com/hc/en-us/articles/900002018926-I-ve-lost-my-mnemonic-backup-what-should-I-do-">Blockstream Green</a>: Settings &gt; Security &gt; Mnemonic </li><li>How to find your seed phrase on <a href="https://support.samourai.io/article/11-forgotten-secret-words">Samourai</a>: Settings &gt; Wallet &gt; Show mnemonic</li><li>How to find your seed phrase on <a href="https://chrome.google.com/webstore/detail/liquality-wallet/kpfopkelmapcoipemfendmdcghnegimn">Liquality</a>: Menu &gt; Backup Seed</li><li>How to find your seed phrase on <a href="https://getumbrel.com/">Umbrel</a>: Settings &gt; Account &gt; Secret words &gt; View</li></ul><p>If this is your first time looking at your seed phrase, make sure to <strong>store a copy of your seed phrase in a secure place!</strong> Consider your seed phrase as your bitcoin. <strong>If you lose access to your seed phrase, you lose your bitcoin. </strong></p><p>This is why having a backup of your seed phrase is important. <strong>Please please please make sure to backup your seed phrase in a safe, secure, and secret location. </strong></p><h2 id="how-should-i-backup-my-seed-phrase">How should I backup my seed phrase? </h2><p>If you're wondering how and where to store your seed phrase backup, here are a few pointers:</p><ul><li>Do NOT save your seed phrase on a computer, phone, etc. You want it to be "air-gapped" from the Internet / a digital environment.</li><li>Consider writing down your seed phrase on paper or stamping it into metal, then store it in a safe location</li></ul><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/seed-phrase-metal-plate-backup-jameson-lopp-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/seed-phrase-metal-plate-backup-jameson-lopp-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/2021/04/seed-phrase-metal-plate-backup-jameson-lopp-bitcoin-briefly.png 709w"><figcaption>https://blog.lopp.net/metal-bitcoin-seed-storage-stress-test-iv/</figcaption></figure><p>I'm going to leave it up to you to figure out how to store you seed phrase backup. Here are some other resources: </p><ul><li><a href="https://en.bitcoin.it/wiki/Seed_phrase#Storing_Seed_Phrases_for_the_Long_Term">Bitcoin Wiki</a></li><li><a href="https://www.lopp.net/bitcoin-information/security.html">Jameson Lopp's Resources</a> </li></ul><p>Ok, so we've gone over:</p><ul><li>Private key = how you own and spend bitcoin</li><li>Seed phrase = a way for your wallet to derive your private key</li><li>Not sharing your seed phrase</li><li>Where to find your seed phrase</li><li>Backing up a copy of your seed phrase</li></ul><p>Now you might be wondering, "when or where can I use my seed phrase?" </p><h2 id="where-can-i-use-my-seed-phrase">Where can I use my seed phrase? </h2><p>Let's say that you lose your Ledger device or wipe your phone. Do you lose access to your bitcoin?</p><p>Well, bitcoin aren't physically stored in your hardware. The Bitcoin blockchain tracks which addresses own which bitcoin. </p><p>So don't worry, you don't lose access to your bitcoin. </p><p><strong>Using your seed phrase backup, you can import your seed phrase into a new wallet.</strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/seed-phrase-meme-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses"><figcaption>Meme: Import Your Seed Phrase by Bitcoin Briefly</figcaption></figure><p>Let's say you were using a Ledger Nano S, lost it, then bought a new one. </p><p>All you need to do is import your existing seed phrase (which you made a backup of) into that new Nano S. That's it. Your Ledger Live dashboard should recover the same bitcoin balances and history.  </p><p>If you were using Blockstream Green, same thing. Type in your seed phrase and it recovers your entire wallet.</p><p>Cool right?</p><p>Now let's say you backed up your seed phrase from your Ledger device. You could even import that seed phrase into Blockstream Green! You could receive or spend bitcoin from either wallet. The apps would show the same wallet activity, balances, addresses, history, etc. </p><p>In fact, <strong>people commonly "transfer" bitcoin from one wallet to another using a seed phrase.</strong> This way, there's no transaction. You don't need to pay transaction fees or wait for mining confirmations. </p><p>So seed phrases can be platform-independent - it's like accessing a cloud service. <strong>All you need is your seed phrase and you can access your bitcoin from any wallet that adheres to BIP39.  </strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/bip39-seed-phrase-compatibility-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses"><figcaption>Meme: BIP39 Seed Phrase Compatibility Amongst Bitcoin Wallets by Bitcoin Briefly</figcaption></figure><p>Do you see why backing up your seed phrase is so important? Do you see why keeping your seed phrase a secret is so important?</p><p>Rather than your hardware or software, your seed phrase is your access to your bitcoin. </p><h2 id="what-is-bip39">What is BIP39?</h2><p><strong><a href="https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki">BIP39</a> specifies how wallets should go about implementing seed phrases for better compatibility</strong>. It also specifies the 2048 word list from which wallets generate seed phrases.</p><p>Most modern wallets are BIP39 compatible and you can find a <a href="https://walletsrecovery.org/">list here</a>. </p><h2 id="how-do-i-import-my-seed-phrase">How do I import my seed phrase? </h2><p>Here's how to import your BIP39 seed phrase into the following wallets. Make sure to enter your seed phrase in sequential order. </p><p>Let me know if I missed any wallets that you'd like to see in the comments below. </p><!--kg-card-begin: html--><p>If you're already comfortable importing seed phrases into wallets, then feel free to <a href="#what-is-a-public-key">skip ahead to the next section</a>.</p><!--kg-card-end: html--><ul><li>How to Import Your Seed Phrase on <a href="https://support.ledger.com/hc/en-us/articles/360005434914-Restore-from-recovery-phrase">Ledger</a></li><li>How to Import Your Seed Phrase on <a href="https://wiki.trezor.io/User_manual:Recovery">Trezor</a></li><li>How to Import Your Seed Phrase on <a href="https://coldcardwallet.com/docs/import">Coldcard</a></li><li>How to Import Your Seed Phrase on <a href="https://help.blockstream.com/hc/en-us/articles/900001382663-Restore-a-Blockstream-Green-wallet">Blockstream Green</a></li><li>How to Import Your Seed Phrase on <a href="https://support.samourai.io/article/7-importing-a-wallet-from-another-app">Samourai</a></li><li>How to Import Your Seed Phrase on <a href="https://chrome.google.com/webstore/detail/liquality-wallet/kpfopkelmapcoipemfendmdcghnegimn">Liquality</a>: First lock your Liquality Wallet. Then, click "Forgot password? Import with seed phrase"</li><li>How to Import Your Seed Phrase on <a href="https://github.com/getumbrel/umbrel-dashboard/pull/85">Umbrel</a>: On umbrel.local/start , during your setup, click "Recover" on the "Note Down Your Secret Words" screen</li></ul><p>So far, we've covered private keys and seed phrases. </p><p><strong>A private key allows you to spend bitcoin. A seed phrase is a human-readable representation of a private key. Your wallet derives your private key from your seed phrase. </strong></p><figure class="kg-card kg-embed-card"><iframe width="356" height="200" src="https://www.youtube.com/embed/kkceoHDuT38?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></figure><p>Now how do these relate to public keys and addresses?</p><p>Well, how does our wallet know which addresses belong to us? How can our wallet spend the bitcoin received by those addresses? </p><h2 id="what-is-a-public-key">What is a Public Key? </h2><p>Like a private key, a public key is also a large number. But instead of using it to send bitcoin, <strong>we use it to receive bitcoin.</strong></p><p>You see, digital keys come in pairs. </p><p>Using cryptography, <strong>a private key generates its corresponding public key</strong>. This establishes a <strong>"one-to-one" relationship</strong> between the two, making a key pair. </p><p>But a public key CANNOT generate its corresponding private key. This makes the one-to-one relationship between a private key and a public key <strong>"one-way". The private key can derive the public key, but not vice versa. </strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/public-key-derivation-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses"><figcaption>Public Key Derivation by Bitcoin Briefly</figcaption></figure><p><strong>So you can't spend bitcoin using a public key. You also can't derive a private key from a public key. So a public key doesn't need to be kept a secret. </strong></p><p>But many believe that you should keep your public keys secret as well, and only share addresses. This topic is out of the scope for this blog post. But if you're interested in learning more, feel free to let me know in the comments below.</p><p>Pretty much, <strong>your wallet uses public keys to receive bitcoin</strong>, not for sending it. And your public key can't compromise your private key.  </p><p>At this point, you might be thinking: "oh so my addresses, where I receive bitcoin, are just public keys." </p><p>Not quite.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/public-key-address-meme-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses"><figcaption>Meme: The Difference between Public Keys and Addresses by Bitcoin Briefly</figcaption></figure><!--kg-card-begin: html--><h2 id="what-is-an-address">What is an <a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/">Address</a>?</h2><!--kg-card-end: html--><p>An address is a <strong>"human-readable" form of its respective public key. It's where you receive bitcoin</strong>. As stated in the <a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/">Practical Guide to Bitcoin Addresses</a>, these addresses typically start with a "bc1", "3", or "1". </p><p>Again, by using one-way cryptographic functions, <strong>a public key generates its corresponding address. </strong>The one-to-one relationship between an address and public key is also one-way. <strong>A public key derives an address, but not vice versa. </strong></p><p>Like their public key counterparts, <strong>addresses don't need to be kept secret.</strong> In fact, you need to share them in order to receive bitcoin.</p><p><strong>So in summary, a seed derives a private key. That private key generates its corresponding public key. That public key then generates its corresponding address. </strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/address-derivation-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses"><figcaption>Address Derivation by Bitcoin Briefly</figcaption></figure><p>This means that <strong>each address relates to a public key, which also relates to a private key. </strong></p><p>This is how our wallet (1) knows that an address belongs to us, and (2) can spend the bitcoin in that address. Private keys and addresses are ultimately linked. </p><p>Thankfully, you do <strong>NOT have to worry about managing your private and public keys when using a wallet.</strong> </p><p>Most wallets abstract away all those concepts. Wallets handle key management in the background. You're only required to know your seed phrase, and how to send and receive bitcoin. </p><p>Tip - you can use <a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/#what-is-my-bitcoin-address-how-to-get-a-bitcoin-address">this guide to find your address within your wallet</a>.</p><!--kg-card-begin: html--><h2 id="why-does-my-bitcoin-address-change"><a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/#why-does-my-bitcoin-address-change">Why does my Bitcoin Address Change?</a></h2><!--kg-card-end: html--><p>"So one private key can generate one public key, and one public key can generate one address. Then how does my wallet generate new addresses for every transaction? I'm only using one private key via my seed phrase!"</p><p>It's a great question because one private key corresponds to one seed phrase. And it's not like you're backing up a seed phrase for every transaction...</p><p>This is where <strong>BIP32 Hierarchical Deterministic (HD) wallets</strong> come into play. </p><h2 id="what-is-a-bip32-hierarchical-deterministic-hd-wallet">What is a BIP32 Hierarchical Deterministic (HD) Wallet?</h2><p><strong>HD wallets can use a single master seed to generate many new key pairs (and in doing so, addresses).</strong> This is why your single seed phrase can generate a new address for every transaction. You are using an HD wallet. </p><p>So if you've received 100 transactions, your HD wallet created 100 key pairs for them.</p><p>Note: HD wallets are not hardware wallets. But hardware wallets are often HD wallets. </p><p>HD wallets are great if you want to <strong><a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/#why-does-my-bitcoin-address-change">avoid address reuse</a> for better privacy and security</strong>. </p><p>They also offer two other advantages.</p><p>First, they use a <strong>tree structure</strong>. This tree structure can express organizational meaning. </p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/photo-1520262454473-a1a82276a574_optimized.jpeg" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/photo-1520262454473-a1a82276a574_optimized.jpeg 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/photo-1520262454473-a1a82276a574_optimized.jpeg 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/photo-1520262454473-a1a82276a574_optimized.jpeg 1600w, https://bitcoinbriefly.com/content/images/2021/04/photo-1520262454473-a1a82276a574_optimized.jpeg 2000w" sizes="(min-width: 720px) 720px"><figcaption>Photo by <a href="https://unsplash.com/@fabulu75?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Fabrice Villard</a> / <a href="https://unsplash.com/?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Unsplash</a></figcaption></figure><p>For example, let's say that I'm running a bitcoin business. </p><ul><li>I can have one branch of the tree represent product sales. That one branch can create a new address for every sale. </li><li>I can have another branch representing donations. That branch can create a new address for every donation. </li><li>I can have another branch representing consulting fees, and so on and so forth. </li></ul><p>With this tree structure, all I need is one HD wallet - I can separate concerns by using different branches. So HD wallets offer more convenience. <strong>They generate addresses on the fly and allow me to separate transactions into groups. </strong></p><p>Compare this to non-HD wallets, where I'd have to create and backup every private key, then organize them into groups. Key management in a non-HD wallet would be a headache!</p><p>FYI - these <strong>branches are often called accounts or sub-accounts</strong>, like in Ledger Live. Also <strong>many HD wallets may offer only one account</strong> for simplicity's sake. Still with one account, you'll be generating addresses for every transaction.</p><p>The second benefit of HD wallets is the <strong>ability to generate private keys and public keys separately.</strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/photo-1519401706-5cf17f6e70de_optimized.jpeg" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/photo-1519401706-5cf17f6e70de_optimized.jpeg 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/photo-1519401706-5cf17f6e70de_optimized.jpeg 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/photo-1519401706-5cf17f6e70de_optimized.jpeg 1600w, https://bitcoinbriefly.com/content/images/2021/04/photo-1519401706-5cf17f6e70de_optimized.jpeg 2000w" sizes="(min-width: 720px) 720px"><figcaption>Photo by <a href="https://unsplash.com/@fairfilter?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Oliver Roos</a> / <a href="https://unsplash.com/?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Unsplash</a></figcaption></figure><p>Let's continue with the bitcoin business example to explain this concept. </p><p>If someone wants to make a donation, my website will tell my HD wallet to create a new address under my "donations" account. </p><p>You'd guess that the wallet first creates a new key pair using the master seed, then displays the respective address, right?</p><p>But what if the GoDaddy server that's hosting my website was insecure? What if GoDaddy was stealing every website's private keys? How could the web server generate a new address for each donation in an insecure environment?</p><p>The web server would need to be able<strong> to generate public keys and addresses without accessing my private keys. </strong></p><p>Without an HD wallet, I'd have to first pre-generate a ton of key pairs. Then, I'd have to put the public keys on the web server. I'd also need to make seed phrase backups for each private key. And I'd have to make sure to separate concerns between the key pairs - noting which keys were used for donations, sales, etc.</p><p>In other words, a headache and recipe for disaster.</p><p>Luckily, an HD wallet comes with this capability. </p><p>I can host something called an <strong>"extended public key" (xpub)</strong> on the web server. This would allow the web server to <strong>create public keys and corresponding addresses ad-hoc</strong> for each donation. Because it's one-way, knowing this xpub would not help GoDaddy in finding my private keys. </p><p>This way, I could <strong>host my xpub and its corresponding public keys and addresses on the web server, while keeping my private keys separated and secure. </strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/hd-wallets-explained-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/hd-wallets-explained-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/hd-wallets-explained-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/04/hd-wallets-explained-bitcoin-briefly.png 1600w, https://bitcoinbriefly.com/content/images/2021/04/hd-wallets-explained-bitcoin-briefly.png 2149w" sizes="(min-width: 720px) 720px"><figcaption>HD Wallets Explained by Bitcoin Briefly</figcaption></figure><p>So if you use an HD wallet, each transaction will use a new private-public key pair and derive an address. Your wallet manages these new private-public key pairs in the background. </p><p>Again, <strong>you only need to know your single master seed phrase. </strong>Amazing right? </p><p>There's a lot of magic that happens behind the scenes in HD wallets, but it's out of the scope for this blog post. If you'd like to learn more about wallets, let me know in the comments below. </p><p>I highly recommend researching topics like:</p><ul><li>Compressed vs. uncompressed keys</li><li>Master private key, master public key, master chain code</li><li>Parent vs. child keys</li><li>BIP44, BIP84, BIP49, BIP43</li><li>Extended Public Key (xPub), Extended Private Key (xPrv)</li><li>Derivation paths</li><li>Digital signatures</li><li>Encodings, Hash functions</li><li>Elliptic curve cryptography</li><li>UTXOs</li></ul><p>Tying all these concepts up...</p><h2 id="what-is-a-wallet">What is a Wallet?</h2><p><strong>Your wallet is your key manager.</strong> It handles all the complexities of key creation, management, etc. for you. All you need to know is your seed phrase and click a few buttons to transact. </p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2021/04/key-master-matrix-reloaded-bitcoin-briefly.png" class="kg-image" alt="The Ultimate Guide to Bitcoin Wallets, Seeds, Private Keys, Public Keys, and Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/04/key-master-matrix-reloaded-bitcoin-briefly.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/04/key-master-matrix-reloaded-bitcoin-briefly.png 1000w, https://bitcoinbriefly.com/content/images/2021/04/key-master-matrix-reloaded-bitcoin-briefly.png 1466w" sizes="(min-width: 720px) 720px"><figcaption>Key Master: Matrix Reloaded&nbsp;</figcaption></figure><h2 id="conclusion">Conclusion</h2><p>So in summary: </p><ul><li>Your seed phrase is a representation of a random number</li><li>Your wallet uses your seed phrase to derive your private key</li><li>Your wallet uses your private key to spend bitcoin</li><li>Your wallet uses your private key to generate a corresponding public key</li><li>Your wallet uses your public key to generate a corresponding address</li><li>You use an address to receive bitcoin</li><li>Hierarchical deterministic (HD) wallets use a single seed phrase to generate many private keys, public keys, and corresponding addresses</li><li>HD wallets can organize key pairs into accounts</li><li>HD wallets can also generate public keys without private keys (except for the master key pair)</li><li>Your wallet is your key manager that abstracts away complexity for a simpler user experience</li></ul><p>Note: if you are using a custodial retail brokerage / exchange like Gemini, Coinbase, CashApp, etc., then you do NOT actually own your bitcoin. On these platforms, you don't own a seed phrase (and its derivatives).</p><p>Hope this blog post helped clarify these technical concepts. If so, let me know what you've learned in the comments below, and feel free to share this post with other beginners who might also be struggling with these concepts!</p><p>What did I miss? What else would you like to learn more about? <a href="https://twitter.com/bitcoin_briefly">Let me know on Twitter</a>!</p><!--kg-card-begin: html--><iframe src="https://bitcoinbriefly.substack.com/embed" width="480" height="320" style="border:1px solid #EEE; background:white;" frameborder="0" scrolling="no"></iframe><!--kg-card-end: html-->]]></content:encoded></item><item><title><![CDATA[A Practical Guide to Bitcoin Addresses]]></title><description><![CDATA[Wondering what bitcoin addresses are; how to find or change them in your wallet or exchange; the differences between prefixes like 1, 3, or bc1; etc.?]]></description><link>https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/</link><guid isPermaLink="false">5ffe0dc98476b84d44a8a4c0</guid><category><![CDATA[Explainers]]></category><dc:creator><![CDATA[Alex Min]]></dc:creator><pubDate>Wed, 13 Jan 2021 13:08:22 GMT</pubDate><media:content url="https://bitcoinbriefly.com/content/images/2021/03/photo-1564241832533-49e2d87687cd.jpeg" medium="image"/><content:encoded><![CDATA[<img src="https://bitcoinbriefly.com/content/images/2021/03/photo-1564241832533-49e2d87687cd.jpeg" alt="A Practical Guide to Bitcoin Addresses"><p>Published: 2021-01-13 at block 665,874<br>Bitcoin Price: $34,100</p><h2 id="table-of-contents">Table of Contents</h2><!--kg-card-begin: html--><ul>
    <li><a href="#what-is-a-bitcoin-wallet-address">What is a Bitcoin Wallet Address?</a></li>
    <li><a href="#what-is-an-example-of-a-bitcoin-address-what-is-the-format">What is an example of a Bitcoin Address? What is the format?</a></li>
    <li><a href="#what-is-my-bitcoin-address-how-to-get-a-bitcoin-address">What is my Bitcoin Address? How to get a bitcoin address?</a></li>
    <ul>
        <li><a href="#how-to-get-a-bitcoin-address-on-cashapp">How to get a bitcoin address on: CashApp</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-coinbase">How to get a bitcoin address on: Coinbase</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-coinbase-pro">How to get a bitcoin address on: Coinbase Pro</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-electrum">How to get a bitcoin address on: Electrum</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-bitcoin-core">How to get a bitcoin address on: Bitcoin Core</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-ledger">How to get a bitcoin address on: Ledger</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-trezor">How to get a bitcoin address on: Trezor</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-blockstream-green">How to get a bitcoin address on: Blockstream Green</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-liquality">How to get a bitcoin address on: Liquality</a></li>
    </ul>
    <li><a href="#looking-up-your-bitcoin-wallet-address-on-a-block-explorer">Looking Up Your Bitcoin Wallet Address on a Block Explorer</a></li>
    <li><a href="#why-does-my-bitcoin-address-change">Why Does My Bitcoin Address Change?</a></li>
    <li><a href="#bitcoin-address-collision">Bitcoin Address Collision</a></li>
    <li><a href="#address-prefixes-1-legacy-3-nested-segwit-bc1-native-segwit-and-how-to-save-money-on-your-bitcoin-transaction-fees">Address Prefixes (1 Legacy, 3 Nested SegWit, bc1 Native SegWit) and How to Save Money on Your Bitcoin Transaction Fees</a></li>
    <ul>
        <li><a href="#prefix-1-legacy-addresses-aka-pay-to-public-key-hash-p2pkh-">Prefix “1”: Legacy Addresses, aka, Pay to Public Key Hash (P2PKH)</a></li>
        <li><a href="#prefix-bc1-native-segwit-bech32-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-">Prefix “bc1”: Native SegWit Bech32 Addresses, aka, Pay to Witness Public Key Hash (P2WPKH)</a></li>
        <li><a href="#prefix-3-nested-segwit-addresses-aka-pay-to-witness-public-key-hash-in-a-pay-to-script-hash-p2sh-p2wpkh-">Prefix “3”: Nested SegWit Addresses, aka, Pay to Witness Public Key Hash in a Pay to Script Hash (P2SH-P2WPKH)</a></li>
    </ul>
    <li><a href="#how-to-use-segwit-addresses">How to Use SegWit Addresses</a></li>
    <ul>
        <li><a href="#how-to-use-native-segwit-bech32-bc1-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-in-ledger-live">How to Use Native SegWit Bech32 “bc1” Addresses, aka, Pay to Witness Public Key Hash (P2WPKH) in Ledger Live</a></li>
        <li><a href="#how-to-use-nested-segwit-3-addresses-aka-pay-to-witness-public-key-hash-in-a-pay-to-script-hash-p2sh-p2wpkh-in-ledger-live">How to Use Nested SegWit “3” Addresses, aka, Pay to Witness Public Key Hash in a Pay to Script Hash (P2SH-P2WPKH) in Ledger Live</a></li>
        <li><a href="#how-to-use-native-segwit-bech32-bc1-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-in-trezor-suite">How to Use Native SegWit Bech32 “bc1” Addresses, aka, Pay to Witness Public Key Hash (P2WPKH) in Trezor Suite</a></li>
        <li><a href="#how-to-use-nested-segwit-3-addresses-aka-pay-to-witness-public-key-hash-in-a-pay-to-script-hash-p2sh-p2wpkh-in-trezor-suite">How to Use Nested SegWit “3” Addresses, aka, Pay to Witness Public Key Hash in a Pay to Script Hash (P2SH-P2WPKH) in Trezor Suite</a></li>
    </ul>
    <li><a href="#segwit-adoption">SegWit Adoption</a></li>
</ul><!--kg-card-end: html--><h2 id="what-is-a-bitcoin-wallet-address">What is a Bitcoin Wallet Address?</h2><p>You can think of a Bitcoin wallet address like a mailing address. It’s a possible <strong>destination for a bitcoin payment</strong>.</p><p>These <strong>public addresses are NOT public keys</strong>. It’s common to confuse the two, but they are completely different. Your wallet uses your private key to create a public key. It then hashes your public key to generate an address. </p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/01/image-7.png" class="kg-image" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/image-7.png 600w, https://bitcoinbriefly.com/content/images/2021/01/image-7.png 875w" sizes="(min-width: 720px) 720px"></figure><p>Also, <strong>addresses are NOT accounts.</strong> An account is an abstract collection of various addresses. </p><p>Private keys vs. public keys vs. addresses vs. accounts is a topic that deserves <a href="https://bitcoinbriefly.com/ultimate-guide-to-bitcoin-wallets-seeds-private-keys-public-keys-and-addresses/">its own article</a>. For the scope of this blog post, we’ll only be dealing with addresses.</p><h2 id="what-is-an-example-of-a-bitcoin-address-what-is-the-format">What is an example of a Bitcoin Address? What is the format? </h2><p>A Bitcoin address looks like <strong>random text, but its format usually begins with a 1, 3, or bc1</strong>. Here are some examples of Bitcoin addresses: </p><ul><li><strong>1</strong>7VZNX1SN5NtKa8UQFxwQbFeFc3iqRYhem</li><li><strong>1</strong>JqDybm2nWTENrHvMyafbSXXtTk5Uv5QAn</li><li><strong>3</strong>EktnHQD7RiAE6uzMj2ZifT9YgRrkSgzQX</li><li><strong>3</strong>279PyBGjZTnu1GNSXamReTj98kiYgZdtW</li><li><strong>bc1</strong>qw508d6qejxtdg4y5r3zarvary0c5xw7kv8f3t4</li><li><strong>bc1</strong>qa5wkgaew2dkv56kfvj49j0av5nml45x9ek9hz6</li></ul><p>Though <a href="https://en.bitcoin.it/wiki/List_of_address_prefixes">other prefixes</a> exist, 1, 3, and bc1 are the most common and relevant to users. </p><!--kg-card-begin: html--><p>Later in the blog post, I explain <a href="#address-prefixes-1-legacy-3-nested-segwit-bc1-native-segwit-and-how-to-save-money-on-your-bitcoin-transaction-fees">the differences between these prefixes</a>. Some of them can even <a href="#prefix-bc1-native-segwit-bech32-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-">save you money when sending transactions</a>.</p><!--kg-card-end: html--><h2 id="what-is-my-bitcoin-address-how-to-get-a-bitcoin-address">What is my Bitcoin Address? How to get a bitcoin address? </h2><p>Does it say <strong>Receive, Deposit, Addresses</strong>, or something like that in your wallet or exchange? You should be able to find your Bitcoin address there (starting with a 1, 3, or bc1) and/or a QR code that represents it.</p><p>For your convenience, I've added screenshots for you to get your bitcoin address on:</p><!--kg-card-begin: html--><ul>
        <li><a href="#how-to-get-a-bitcoin-address-on-cashapp">How to get a bitcoin address on: CashApp</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-coinbase">How to get a bitcoin address on: Coinbase</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-coinbase-pro">How to get a bitcoin address on: Coinbase Pro</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-electrum">How to get a bitcoin address on: Electrum</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-bitcoin-core">How to get a bitcoin address on: Bitcoin Core</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-ledger">How to get a bitcoin address on: Ledger</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-trezor">How to get a bitcoin address on: Trezor</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-blockstream-green">How to get a bitcoin address on: Blockstream Green</a></li>
        <li><a href="#how-to-get-a-bitcoin-address-on-liquality">How to get a bitcoin address on: Liquality</a></li>
    </ul><!--kg-card-end: html--><p>Let me know in the comments section at the bottom of the page if I missed any that you’d like to see!</p><h3 id="how-to-get-a-bitcoin-address-on-cashapp">How to get a bitcoin address on: CashApp</h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.04.37-AM.png" width="806" height="1324" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.04.37-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.04.37-AM.png 806w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.05.00-AM.png" width="803" height="1343" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.05.00-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.05.00-AM.png 803w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.05.21-AM.png" width="807" height="1338" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.05.21-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.05.21-AM.png 807w" sizes="(min-width: 720px) 720px"></div></div></div></figure><h3 id="how-to-get-a-bitcoin-address-on-coinbase">How to get a bitcoin address on: Coinbase</h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-4.08.18-PM.png" width="300" height="485" alt="A Practical Guide to Bitcoin Addresses"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-9.34.41-AM-1.png" width="367" height="535" alt="A Practical Guide to Bitcoin Addresses"></div></div></div></figure><h3 id="how-to-get-a-bitcoin-address-on-coinbase-pro">How to get a bitcoin address on: Coinbase Pro</h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-9.53.01-AM.png" width="271" height="320" alt="A Practical Guide to Bitcoin Addresses"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-9.47.21-AM.png" width="416" height="703" alt="A Practical Guide to Bitcoin Addresses"></div></div></div></figure><h3 id="how-to-get-a-bitcoin-address-on-electrum">How to get a bitcoin address on: Electrum</h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.11.22-AM.png" width="941" height="481" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.11.22-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.11.22-AM.png 941w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.16.39-AM.png" width="941" height="482" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.16.39-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.16.39-AM.png 941w" sizes="(min-width: 720px) 720px"></div></div></div></figure><h3 id="how-to-get-a-bitcoin-address-on-bitcoin-core">How to get a bitcoin address on: Bitcoin Core</h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.23.01-AM.png" width="623" height="521" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.23.01-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.23.01-AM.png 623w"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.23.42-AM.png" width="1254" height="1183" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.23.42-AM.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/Screen-Shot-2021-01-09-at-10.23.42-AM.png 1000w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.23.42-AM.png 1254w" sizes="(min-width: 720px) 720px"></div></div></div></figure><h3 id="how-to-get-a-bitcoin-address-on-ledger">How to get a bitcoin address on: Ledger </h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-4.13.15-PM.png" width="1012" height="441" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-12-at-4.13.15-PM.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/Screen-Shot-2021-01-12-at-4.13.15-PM.png 1000w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-4.13.15-PM.png 1012w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-4.13.25-PM.png" width="1007" height="596" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-12-at-4.13.25-PM.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/Screen-Shot-2021-01-12-at-4.13.25-PM.png 1000w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-4.13.25-PM.png 1007w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-9.50.45-AM.png" width="495" height="646" alt="A Practical Guide to Bitcoin Addresses"></div></div></div></figure><h3 id="how-to-get-a-bitcoin-address-on-trezor">How to get a bitcoin address on: Trezor</h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.19.00-AM.png" width="905" height="651" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.19.00-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.19.00-AM.png 905w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.19.15-AM.png" width="906" height="650" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.19.15-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.19.15-AM.png 906w" sizes="(min-width: 720px) 720px"></div></div><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.19.38-AM.png" width="905" height="644" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.19.38-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.19.38-AM.png 905w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.20.08-AM.png" width="906" height="650" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-09-at-10.20.08-AM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.20.08-AM.png 906w" sizes="(min-width: 720px) 720px"></div></div></div></figure><h3 id="how-to-get-a-bitcoin-address-on-blockstream-green">How to get a bitcoin address on: Blockstream Green</h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/IMG_2558.PNG" width="1125" height="2436" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/IMG_2558.PNG 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/IMG_2558.PNG 1000w, https://bitcoinbriefly.com/content/images/2021/01/IMG_2558.PNG 1125w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/IMG_2559.PNG" width="1125" height="2436" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/IMG_2559.PNG 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/IMG_2559.PNG 1000w, https://bitcoinbriefly.com/content/images/2021/01/IMG_2559.PNG 1125w" sizes="(min-width: 720px) 720px"></div></div></div></figure><h3 id="how-to-get-a-bitcoin-address-on-liquality">How to get a bitcoin address on: Liquality</h3><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.28.23-AM-1.png" width="358" height="337" alt="A Practical Guide to Bitcoin Addresses"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.28.38-AM-1.png" width="356" height="293" alt="A Practical Guide to Bitcoin Addresses"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-09-at-10.28.47-AM-1.png" width="359" height="596" alt="A Practical Guide to Bitcoin Addresses"></div></div></div></figure><h2 id="looking-up-your-bitcoin-wallet-address-on-a-block-explorer">Looking Up Your Bitcoin Wallet Address on a Block Explorer</h2><p>Ok, so you know where to find your bitcoin addresses within your wallet or exchange. These should display your <strong>addresses' activities and transaction histories.</strong></p><p>In case they don't or you want to see more details, you can <strong>use a block explorer</strong>.</p><p>Remember, the Bitcoin blockchain and all transactions recorded on it are public. So you can find your addresses' histories on the blockchain through a block explorer. </p><p>It’s like viewing a shipped order on Fedex. On Fedex, you enter your tracking number. You then get its details, like when your package shipped, etc. </p><p><strong>Like with Fedex, you can enter your address into a block explorer. It will then display the address' transaction history.</strong></p><p>You can use block explorers like:</p><ul><li><a href="https://mempool.space/">https://mempool.space/</a></li><li><a href="https://blockstream.info/">https://blockstream.info/</a></li><li><a href="https://blockchair.com/bitcoin/">https://blockchair.com/bitcoin/</a></li><li><a href="https://www.blockchain.com/explorer">https://www.blockchain.com/explorer</a></li><li><a href="https://btc.com/">https://btc.com/</a></li><li><a href="https://github.com/janoside/btc-rpc-explorer">https://github.com/janoside/btc-rpc-explorer</a></li></ul><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-10-at-1.28.08-PM-1.png" width="1122" height="1048" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-10-at-1.28.08-PM-1.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/Screen-Shot-2021-01-10-at-1.28.08-PM-1.png 1000w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-10-at-1.28.08-PM-1.png 1122w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-10-at-1.28.25-PM-1.png" width="961" height="1332" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-10-at-1.28.25-PM-1.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-10-at-1.28.25-PM-1.png 961w" sizes="(min-width: 720px) 720px"></div></div><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-10-at-1.28.55-PM-1.png" width="1057" height="1334" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-10-at-1.28.55-PM-1.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/Screen-Shot-2021-01-10-at-1.28.55-PM-1.png 1000w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-10-at-1.28.55-PM-1.png 1057w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-10-at-1.35.15-PM-1.png" width="1002" height="1334" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-10-at-1.35.15-PM-1.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/Screen-Shot-2021-01-10-at-1.35.15-PM-1.png 1000w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-10-at-1.35.15-PM-1.png 1002w" sizes="(min-width: 720px) 720px"></div></div></div></figure><p>But if you're <strong>privacy conscious, you should <a href="https://github.com/janoside/btc-rpc-explorer">host your own</a> block explorer. </strong>Also consider connecting to one <strong>using Tor</strong>.  Why? Because if you're typing unique addresses into an online service, they can map that to your device.</p><p>If you'd like a tutorial on hosting your own block explorer, let me know in the comments below.</p><p>Regardless, knowing how to use a block explorer is a <strong>key skill</strong> to have within the world of Bitcoin. It's like knowing how to use Google. Give it a try using the example addresses in the beginning of this blog post.</p><p>I've covered <a href="https://bitcoinbriefly.com/so-your-bitcoin-transaction-is-stuck/">block explorers, transaction fee rates, and mempools</a> in another blog post. I recommend reading it if you haven't already.</p><p><em>Side note: I've also created a <a href="https://bitcoinbriefly.com/how-to-use-mempool-space-block-explorer/">full guide on how to use mempool.space</a>.</em></p><h2 id="why-does-my-bitcoin-address-change">Why Does My Bitcoin Address Change?</h2><p>Depending on your software, you might notice that your Bitcoin address often changes. Don't worry, this is <strong>standard practice and good for your privacy and security</strong>!</p><p>Changing addresses can be confusing to new users. They expect their Bitcoin address to stay the same, like their home address. </p><p>But Bitcoin addresses are more like tissues - they're <strong>disposable for each transaction</strong>. Reusing Bitcoin addresses is not "sanitary" for your privacy and security. </p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://images.unsplash.com/photo-1607166547650-8ba1b4a280df?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDR8fHRpc3N1ZXxlbnwwfHx8&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2000" class="kg-image" alt="A Practical Guide to Bitcoin Addresses" srcset="https://images.unsplash.com/photo-1607166547650-8ba1b4a280df?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDR8fHRpc3N1ZXxlbnwwfHx8&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=600 600w, https://images.unsplash.com/photo-1607166547650-8ba1b4a280df?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDR8fHRpc3N1ZXxlbnwwfHx8&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=1000 1000w, https://images.unsplash.com/photo-1607166547650-8ba1b4a280df?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDR8fHRpc3N1ZXxlbnwwfHx8&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=1600 1600w, https://images.unsplash.com/photo-1607166547650-8ba1b4a280df?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDR8fHRpc3N1ZXxlbnwwfHx8&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2400 2400w" sizes="(min-width: 720px) 720px"><figcaption>Photo by <a href="https://unsplash.com/@umbra_media?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Christopher Bill</a> / <a href="https://unsplash.com/?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Unsplash</a></figcaption></figure><p>Again, the Bitcoin blockchain and all transactions recorded on it are public. Whoever receives bitcoin from you can see your address and its history. If you reuse the same address, they can easily find out your Bitcoin savings and more by using a block explorer. </p><p>So you should <strong>avoid reusing addresses</strong>. Fortunately, BIP32 hierarchical deterministic (HD) wallets make this very easy. </p><p>The HD wallet topic is outside the scope of this blog post. But in short, these wallets generate a ton of addresses for you using a single private key, and are now the standard. Make sure not to confuse HD wallets with hardware wallets.</p><p>If you're interested in learning more about BIP32 HD wallets and the differences between private keys vs. public keys vs. addresses vs. accounts, <a href="https://bitcoinbriefly.com/ultimate-guide-to-bitcoin-wallets-seeds-private-keys-public-keys-and-addresses/">check out this blog post</a>.</p><h2 id="bitcoin-address-collision">Bitcoin Address Collision</h2><p>You might be wondering: "If we're all using new addresses for every transaction, can we ever generate duplicates of addresses already in use?"</p><p>As covered in the Bitcoin <a href="https://en.bitcoin.it/wiki/Technical_background_of_version_1_Bitcoin_addresses#:~:text=Since%20Bitcoin%20addresses%20are%20basically,money%20sent%20to%20that%20address">Wiki</a>, Bitcoin addresses are basically random numbers. <strong>It's possible, although extremely unlikely, for two people to generate the same address. </strong></p><p>Bitcoiners call this an address collision. If this happens, then either person could spend the bitcoin sent to that address.</p><p>But there are so many potential addresses that it's pretty much impossible. </p><p>Murch, a highly-respected Bitcoin engineer and moderator of the Bitcoin Stack Exchange, <a href="https://bitcoin.stackexchange.com/questions/8804/is-each-bitcoin-address-unique/12740#12740">explains</a>:</p><ul><li>There are 2^160 possible addresses. More specifically, 1,461,501,637,330,902,918,203,684,832,716,283,019,655,932,542,976, ie., 1.461 quindecillion addresses.</li><li>To put this number into perspective, there are only <a href="https://bitcointalk.org/index.php?topic=24268.msg304212#msg304212">2^63 grains of sand on all beaches</a> on Earth, ie., 9.223 quintillion.</li><li>As of 2021-01-10, there are about 34 million addresses in use. Even at 1 trillion addresses, the chance for an address collision is 3.42*10^(-27), ie. 0.000000000000000000000000342%. <strong>You have a much better chance at winning the lottery</strong> (0.0000071511238%) <strong>or getting struck by lightning</strong> (0.0002%).</li><li>It'd be easier to generate random private keys, calculate the corresponding addresses, and hope to find an address that has funds.</li></ul><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://images.unsplash.com/photo-1593453917923-c3f751aab514?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDJ8fGxvdHRlcnl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2000" class="kg-image" alt="A Practical Guide to Bitcoin Addresses" srcset="https://images.unsplash.com/photo-1593453917923-c3f751aab514?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDJ8fGxvdHRlcnl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=600 600w, https://images.unsplash.com/photo-1593453917923-c3f751aab514?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDJ8fGxvdHRlcnl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=1000 1000w, https://images.unsplash.com/photo-1593453917923-c3f751aab514?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDJ8fGxvdHRlcnl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=1600 1600w, https://images.unsplash.com/photo-1593453917923-c3f751aab514?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDJ8fGxvdHRlcnl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2400 2400w" sizes="(min-width: 720px) 720px"><figcaption>Photo by <a href="https://unsplash.com/@waldemarbrandt67w?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Waldemar Brandt</a> / <a href="https://unsplash.com/?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Unsplash</a></figcaption></figure><p>But let’s say there was an address collision. Would it be possible for either person to spend the funds of the entire wallet? Not if they avoid address reuse! They can <strong>only spend the funds associated with that one address.</strong></p><h2 id="address-prefixes-1-legacy-3-nested-segwit-bc1-native-segwit-and-how-to-save-money-on-your-bitcoin-transaction-fees">Address Prefixes (1 Legacy, 3 Nested SegWit, bc1 Native SegWit) and How to Save Money on Your Bitcoin Transaction Fees</h2><p>At this point, we’ve covered:</p><!--kg-card-begin: html--><ul>
    <li><a href="#what-is-a-bitcoin-wallet-address">What is a Bitcoin Wallet Address (not a public key)</a></li>
    <li><a href="#what-is-an-example-of-a-bitcoin-address-what-is-the-format">What does a Bitcoin address look like (1, 3, bc1)</a></li>
    <li><a href="#what-is-my-bitcoin-address-how-to-get-a-bitcoin-address">Where to find your Bitcoin address in your wallet or exchange</a></li>
    <li><a href="#looking-up-your-bitcoin-wallet-address-on-a-block-explorer">How to look up your Bitcoin address in a block explorer</a></li>
    <li><a href="#why-does-my-bitcoin-address-change">Why your Bitcoin address changes (HD wallet)</a></li>
    <li><a href="#bitcoin-address-collision">How unlikely Bitcoin address collisions are to happen</a></li>
</ul><!--kg-card-end: html--><p>Now let’s dive deeper into the technicalities of addresses. If you’re using an address that starts with a “1”, you'll be able to <strong>save 80% on transaction fees</strong> by the end of this blog post.</p><!--kg-card-begin: html--><p><a href="#what-is-a-bitcoin-wallet-address">As mentioned above</a>, users’ <b>Bitcoin addresses look like random text, but usually begin with a 1, 3, or bc1:</b></p><!--kg-card-end: html--><ul><li><strong>1</strong>7VZNX1SN5NtKa8UQFxwQbFeFc3iqRYhem</li><li><strong>1</strong>JqDybm2nWTENrHvMyafbSXXtTk5Uv5QAn</li><li><strong>3</strong>EktnHQD7RiAE6uzMj2ZifT9YgRrkSgzQX</li><li><strong>3</strong>279PyBGjZTnu1GNSXamReTj98kiYgZdtW</li><li><strong>bc1</strong>qw508d6qejxtdg4y5r3zarvary0c5xw7kv8f3t4</li><li><strong>bc1</strong>qa5wkgaew2dkv56kfvj49j0av5nml45x9ek9hz6</li></ul><p>Let’s break down the prefixes one by one:</p><h3 id="prefix-1-legacy-addresses-aka-pay-to-public-key-hash-p2pkh-">Prefix “1”: Legacy Addresses, aka, Pay to Public Key Hash (P2PKH)</h3><figure class="kg-card kg-embed-card"><iframe width="356" height="200" src="https://www.youtube.com/embed/f--WjLzC7-k?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></figure><ul><li><strong>1</strong>7VZNX1SN5NtKa8UQFxwQbFeFc3iqRYhe</li><li><strong>1</strong>JqDybm2nWTENrHvMyafbSXXtTk5Uv5QAn</li></ul><p><strong>Legacy addresses start with the digit “1”</strong>. These <strong>Pay-to-Public-Key-Hash (P2PKH)</strong> addresses were once the standard address type up until August 2017. Many now <strong>advise against using them</strong>. Why?</p><p>Legacy addresses incur the <strong>most expensive transaction fees</strong> when sending payments. They also limit the Bitcoin network's ability to scale. And their case-sensitive nature often causes unwanted errors.</p><p>Even though they have many drawbacks, some incompetent wallets and exchanges still use this address type. If your vendor is still using Legacy addresses, let me know in the comments below.</p><h3 id="prefix-bc1-native-segwit-bech32-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-">Prefix “bc1”: Native SegWit Bech32 Addresses, aka, Pay to Witness Public Key Hash (P2WPKH)</h3><figure class="kg-card kg-embed-card"><iframe width="356" height="200" src="https://www.youtube.com/embed/1qFu0Qwbl1Y?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></figure><ul><li><strong>bc1</strong>qw508d6qejxtdg4y5r3zarvary0c5xw7kv8f3t4</li><li><strong>bc1</strong>qa5wkgaew2dkv56kfvj49j0av5nml45x9ek9hz6</li></ul><p><strong>Native SegWit Bech32 "Pay-to-witness-public-key-hash" (P2WPKH) addresses are the standard now</strong>. If you send bitcoin from these <strong>“bc1”</strong> addresses, you can <strong>save up to 80% in transaction fees vs. legacy addresses</strong>. They also help the network scale and are case-insensitive. </p><p>SegWit (Segregated Witness) is a topic that deserves its own blog post. But for the scope of this article, know that <strong>SegWit reduces transaction sizes</strong>. With smaller transaction sizes:</p><ul><li><strong>You pay less in transaction fees</strong></li><li>Miners can fit more transactions into a block</li><li>The network has higher throughput, <strong>confirming more transactions faster</strong></li></ul><p>These Native SegWit Bech32 addresses are backwards-compatible with legacy addresses. But you need to <strong>be careful. </strong></p><p>Don't transact with "bc1" addresses if your wallet or exchange doesn't support them. You might lose your funds! <strong>Check in with your vendor to see whether they support Bech32 addresses</strong>. </p><p>Does your wallet or exchange vendor NOT support “bc1” addresses? Let me know in the comments below.</p><p><em>Side note: bech32 is pronounced like "besh thirty two".</em></p><p>Before teaching you how to switch to bech32 addresses, you should know about...</p><h3 id="prefix-3-nested-segwit-addresses-aka-pay-to-witness-public-key-hash-in-a-pay-to-script-hash-p2sh-p2wpkh-">Prefix “3”: Nested SegWit Addresses, aka, Pay to Witness Public Key Hash in a Pay to Script Hash (P2SH-P2WPKH)</h3><figure class="kg-card kg-embed-card"><iframe width="356" height="200" src="https://www.youtube.com/embed/2dxWL3x4-V8?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></figure><ul><li><strong>3</strong>EktnHQD7RiAE6uzMj2ZifT9YgRrkSgzQX</li><li><strong>3</strong>279PyBGjZTnu1GNSXamReTj98kiYgZdtW</li></ul><p><strong>Nested SegWit addresses start with the digit “3”</strong>. They are also known as <strong>“Pay-to-witness-public-key-hash in a Pay-to-script-hash” (P2SH-P2WPKH) </strong>addresses. </p><p>Nested SegWit addresses are the <strong>middle ground</strong> between Legacy and Native SegWit addresses. They have some of the benefits of Native SegWit but not all.</p><p>They are still case sensitive like legacy addresses. But like bech32 addresses, they have a smaller footprint. Spending from this address type can <strong>save you up to 40% in transaction fees vs. legacy addresses. </strong></p><p>As mentioned above, Native SegWit is backwards-compatible with other address types. But unfortunately, there are wallets and exchanges that only understand legacy addresses. Because they don't yet support "bc1" addresses, they need a workaround. <strong>Nested SegWit "3" addresses fill that void.</strong></p><p>Smart developers wrapped a Native SegWit P2WPKH in a legacy-friendly P2SH. <strong>By using these "3" addresses, users could save on transaction fees in a legacy context. </strong></p><p>In theory, transacting with Nested SegWit addresses shouldn't be an issue. Still, <strong>I'd recommend checking in with your wallet or exchange before transacting.</strong></p><h2 id="how-to-use-segwit-addresses">How to Use SegWit Addresses</h2><p>You need to know:</p><ul><li>Does the wallet or exchange, <strong>where your bitcoin is currently stored</strong>, support Native or Nested SegWit? </li><li>Does the wallet or exchange, <strong>where you will send bitcoin</strong>, support Native or Nested SegWit?</li></ul><p>To find out, you might want to use this <a href="https://bitcoinops.org/en/compatibility/#segwit-addresses">compatibility matrix</a>:</p><ul><li>"P2SH-wrapped" refers to "3" addresses (Nested SegWit)</li><li>"P2SH-P2WPKH" refers to "3" addresses (Nested SegWit)</li><li>"Bech32" refers to "bc1" addresses (Native SegWit)</li><li>"P2WPKH" refers to "bc1" addresses (Native SegWit)</li><li>"P2PKH" refers to "1" addresses (Legacy)</li></ul><p>Still, <strong>make sure to double-check with your vendor</strong>. If neither the sender’s wallet nor the receiver’s wallet supports SegWit, it could result in lost funds.</p><p>For your convenience, I've added screenshots for you to get your bitcoin address on:</p><p>Ledger Live</p><!--kg-card-begin: html--><ul>
    <li><a href="#how-to-use-native-segwit-bech32-bc1-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-in-ledger-live">How to use Native SegWit Bech32 "bc1" Addresses in Ledger Live</a></li>
    <li><a href="#how-to-use-nested-segwit-3-addresses-aka-pay-to-witness-public-key-hash-in-a-pay-to-script-hash-p2sh-p2wpkh-in-ledger-live">How to use Nested SegWit "3" Addresses in Ledger Live</a></li>
</ul><!--kg-card-end: html--><p>Trezor Suite</p><!--kg-card-begin: html--><ul>
    <li><a href="#how-to-use-native-segwit-bech32-bc1-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-in-trezor-suite">How to use Native SegWit Bech32 "bc1" Addresses in Trezor Suite</a></li>
    <li><a href="#how-to-use-nested-segwit-3-addresses-aka-pay-to-witness-public-key-hash-in-a-pay-to-script-hash-p2sh-p2wpkh-in-trezor-suite">How to use Nested SegWit "3" Addresses in Trezor Suite</a></li>
</ul><!--kg-card-end: html--><p>Are there any other examples you’d like to see? Let me know in the comments below.</p><h3 id="how-to-use-native-segwit-bech32-bc1-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-in-ledger-live">How to Use Native SegWit Bech32 “bc1” Addresses, aka, Pay to Witness Public Key Hash (P2WPKH) in Ledger Live</h3><p>Ok, let’s say that you’re using legacy “1” addresses in a Ledger Wallet. Ledger supports Native SegWit. </p><p>To gain the benefits of Native SegWit Bech32 addresses, all you need to do is<strong> send funds from your legacy “1” addresses to a "bc1" address.</strong> </p><p>In Ledger Live, you’ll first need to “Add an Account” to add a “bc1” address:</p><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.05.23-PM.png" width="748" height="381" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-12-at-3.05.23-PM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.05.23-PM.png 748w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.05.54-PM.png" width="495" height="324" alt="A Practical Guide to Bitcoin Addresses"></div></div><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.06.36-PM.png" width="495" height="639" alt="A Practical Guide to Bitcoin Addresses"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.06.44-PM.png" width="491" height="482" alt="A Practical Guide to Bitcoin Addresses"></div></div></div></figure><p>Now you can navigate to your new Native SegWit account and get a “bc1” receive address:</p><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.06.54-PM.png" width="765" height="433" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-12-at-3.06.54-PM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.06.54-PM.png 765w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.07.08-PM.png" width="496" height="350" alt="A Practical Guide to Bitcoin Addresses"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.07.35-PM.png" width="493" height="646" alt="A Practical Guide to Bitcoin Addresses"></div></div></div></figure><p>Once you’ve copied your Native SegWit address, go to your existing Legacy account and send funds to that new “bc1” address:</p><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.08.16-PM.png" width="764" height="338" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-12-at-3.08.16-PM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.08.16-PM.png 764w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.08.26-PM.png" width="493" height="508" alt="A Practical Guide to Bitcoin Addresses"></div></div><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.08.52-PM.png" width="496" height="707" alt="A Practical Guide to Bitcoin Addresses"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.09.17-PM.png" width="492" height="581" alt="A Practical Guide to Bitcoin Addresses"></div></div></div></figure><p>So you’ve sent funds from your Legacy “1” address to your Native SegWit “bc1” address. You can navigate back to your Native SegWit account and view the balance and transaction history:</p><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.14.30-PM.png" width="747" height="680" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-12-at-3.14.30-PM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.14.30-PM.png 747w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.22.09-PM.png" width="739" height="104" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-12-at-3.22.09-PM.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.22.09-PM.png 739w" sizes="(min-width: 720px) 720px"></div></div></div></figure><p>It’s that simple! <strong>Now you will save a ton on transaction fees when you spend from this Native SegWit address.</strong></p><h3 id="how-to-use-nested-segwit-3-addresses-aka-pay-to-witness-public-key-hash-in-a-pay-to-script-hash-p2sh-p2wpkh-in-ledger-live">How to Use Nested SegWit “3” Addresses, aka, Pay to Witness Public Key Hash in a Pay to Script Hash (P2SH-P2WPKH) in Ledger Live</h3><p>Ok, let’s say that you’re using legacy “1” addresses in a Ledger Wallet. Ledger supports Nested SegWit. </p><p>To gain the benefits of Nested SegWit “3” addresses, all you need to do is <strong>send funds from your legacy “1” addresses to a "3" address. </strong></p><p>Similar to the example above, you’ll first need to “Add Account” to add a “3” address in Ledger Live:</p><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.05.23-PM-1.png" width="748" height="381" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-12-at-3.05.23-PM-1.png 600w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.05.23-PM-1.png 748w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.05.54-PM-1.png" width="495" height="324" alt="A Practical Guide to Bitcoin Addresses"></div></div><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.26.56-PM.png" width="495" height="638" alt="A Practical Guide to Bitcoin Addresses"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-12-at-3.06.44-PM-1.png" width="491" height="482" alt="A Practical Guide to Bitcoin Addresses"></div></div></div></figure><!--kg-card-begin: html--><p>Now that you have a Nested SegWit account, you can follow the <a href="#how-to-use-native-segwit-bech32-bc1-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-in-ledger-live">same steps above in the previous section</a> - but of course - instead of using a “bc1” address from your Native SegWit account, use a “3” address from your Nested SegWit account.</p><!--kg-card-end: html--><p>That’s it! <strong>Now you'll save up to 40% on transaction fees. </strong></p><h3 id="how-to-use-native-segwit-bech32-bc1-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-in-trezor-suite">How to Use Native SegWit Bech32 “bc1” Addresses, aka, Pay to Witness Public Key Hash (P2WPKH) in Trezor Suite</h3><p>Ok, let’s say that you’re using legacy “1” addresses in a Trezor Wallet. Trezor supports Native SegWit. </p><p>To gain the benefits of Native SegWit Bech32 addresses, all you need to do is<strong> send funds from your legacy “1” addresses to a "bc1" address.</strong> </p><p>Add a "bc1" Native SegWit Bech32 address:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/01/0_ZOxnKucmcThs_vvx.png" class="kg-image" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/0_ZOxnKucmcThs_vvx.png 600w, https://bitcoinbriefly.com/content/images/2021/01/0_ZOxnKucmcThs_vvx.png 700w"></figure><p>Go to your new "bc1" account, click on the "Receive" tab, then click "Show full address":</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/01/0_wt8q65wo3RSM64F9.png" class="kg-image" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/0_wt8q65wo3RSM64F9.png 600w, https://bitcoinbriefly.com/content/images/2021/01/0_wt8q65wo3RSM64F9.png 700w"></figure><p>Go to your old "1" account, click on the "Send" tab, then enter the new "bc1" address you just got:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/01/0_WvH5AAS4WafjUdka.png" class="kg-image" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/0_WvH5AAS4WafjUdka.png 600w, https://bitcoinbriefly.com/content/images/2021/01/0_WvH5AAS4WafjUdka.png 700w"></figure><p>Add the rest of the transaction details like the amount you want to send from your Legacy address to your Bech32 address. Once it confirms,<strong> you can spend funds from your new Native SegWit account, saving up to 80% on transaction fees! </strong></p><h3 id="how-to-use-nested-segwit-3-addresses-aka-pay-to-witness-public-key-hash-in-a-pay-to-script-hash-p2sh-p2wpkh-in-trezor-suite">How to Use Nested SegWit “3” Addresses, aka, Pay to Witness Public Key Hash in a Pay to Script Hash (P2SH-P2WPKH) in Trezor Suite</h3><p>Ok, let’s say that you’re using legacy “1” addresses in a Trezor Wallet. Trezor supports Nested SegWit. </p><p>To gain the benefits of Nested SegWit “3” addresses, all you need to do is <strong>send funds from your legacy “1” addresses to a "3" address. </strong></p><p>Similar to the example above, you’ll first need to “Add Account” to add a “3” address in Trezor Suite:</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/01/0_ZOxnKucmcThs_vvx--1-.png" class="kg-image" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/0_ZOxnKucmcThs_vvx--1-.png 600w, https://bitcoinbriefly.com/content/images/2021/01/0_ZOxnKucmcThs_vvx--1-.png 700w"></figure><!--kg-card-begin: html--><p>Now that you have a Nested SegWit account, you can follow the <a href="#how-to-use-native-segwit-bech32-bc1-addresses-aka-pay-to-witness-public-key-hash-p2wpkh-in-trezor-suite">same steps above in the previous section</a> - but of course - instead of using a “bc1” address from your Native SegWit account, use a “3” address from your Nested SegWit account.</p><!--kg-card-end: html--><p>That’s it! <strong>Now you'll save up to 40% on transaction fees. </strong></p><h2 id="segwit-adoption">SegWit Adoption</h2><p>Before ending the blog post, I want to leave you with another resource for checking SegWit adoption.</p><p>Though many wallets and exchanges have yet to implement support for Native Bech32 addresses, many support Nested “3” addresses.</p><p>Since SegWit's activation on 2017-08-24, <strong>transactions that spend from SegWit addresses now represent ⅔ of daily Bitcoin transactions</strong>. You can use <a href="https://transactionfee.info/charts/payments-spending-segwit/">this chart</a> to see <strong>SegWit adoption</strong> over time.</p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-13-at-7.58.14-AM.png" class="kg-image" alt="A Practical Guide to Bitcoin Addresses" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/01/Screen-Shot-2021-01-13-at-7.58.14-AM.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/01/Screen-Shot-2021-01-13-at-7.58.14-AM.png 1000w, https://bitcoinbriefly.com/content/images/2021/01/Screen-Shot-2021-01-13-at-7.58.14-AM.png 1128w" sizes="(min-width: 720px) 720px"></figure><p>Looking to learn more about SegWit? Feel free to let me know in the comments below.</p><hr><p>Hope you found this blog post helpful - if you did, please share the article to those who might need it and make sure to subscribe to the newsletter to stay up to date on the latest posts!</p><!--kg-card-begin: html--><iframe src="https://bitcoinbriefly.substack.com/embed" width="480" height="320" style="border:1px solid #EEE; background:white;" frameborder="0" scrolling="no"></iframe><!--kg-card-end: html--><p>What did I miss? What else would you like to learn more about? Let me know in the comments below!</p>]]></content:encoded></item><item><title><![CDATA[So Your Bitcoin Transaction Is Stuck...]]></title><description><![CDATA[You were expecting your bitcoin transaction to get mined and confirmed within the next block (~10 minutes), but for some reason your transaction isn’t going through. 

Sound familiar? Read the blog post]]></description><link>https://bitcoinbriefly.com/so-your-bitcoin-transaction-is-stuck/</link><guid isPermaLink="false">5febab788476b84d44a8a289</guid><category><![CDATA[Explainers]]></category><dc:creator><![CDATA[Alex Min]]></dc:creator><pubDate>Wed, 30 Dec 2020 14:58:00 GMT</pubDate><media:content url="https://bitcoinbriefly.com/content/images/2021/03/dan-gold-kARZuSYMfrA-unsplash.jpg" medium="image"/><content:encoded><![CDATA[<img src="https://bitcoinbriefly.com/content/images/2021/03/dan-gold-kARZuSYMfrA-unsplash.jpg" alt="So Your Bitcoin Transaction Is Stuck..."><p>Published: 2020-12-30 at block 663,688<br>Bitcoin Price: $28,100</p><h2 id="table-of-contents">Table of Contents</h2><!--kg-card-begin: html--><ul>
    <li><a href="#my-bitcoin-transaction-is-stuck-and-unconfirmed">My Bitcoin Transaction is Stuck and Unconfirmed</a></li>
    <li><a href="#how-do-miners-prioritize-transactions">How Do Miners Prioritize Transactions?</a></li>
    <li><a href="#but-i-didn-t-even-set-the-fee-rate-it-was-done-automatically-by-my-wallet-">But I didn’t even set the fee rate - it was done automatically by my wallet.</a></li>
    <li><a href="#so-then-where-in-the-queue-is-my-transaction">So then where in the queue is my transaction?</a></li>
    <li><a href="#what-do-the-different-colored-layers-in-the-mempool-visualizer-represent">What do the different colored layers in the mempool visualizer represent?</a></li>
    <li><a href="#reading-the-mempool">Reading the Mempool</a></li>
    <li><a href="#getting-an-eta-for-your-bitcoin-transaction">Getting an ETA for your Bitcoin Transaction</a></li>
    <li><a href="#where-can-i-see-what-fee-rate-i-paid-for-my-transaction">Where can I see what fee rate I paid for my transaction?</a></li>
    <li><a href="#so-what-can-i-do-for-my-unconfirmed-transaction">So what can I do for my unconfirmed transaction?</a></li>
    <li><a href="#what-does-an-rbf-transaction-look-like">What does an RBF transaction look like?</a></li>
    <li><a href="#walking-through-a-replace-by-fee-rbf-transaction">Walking through a Replace By Fee (RBF) Transaction</a></li>
    <li><a href="#wrapping-up">Wrapping Up</a></li>
    <li><a href="#other-techniques-to-reduce-transaction-fees-and-further-fee-optimization">Other Techniques to Reduce Transaction Fees and Further Fee Optimization</a></li>
</ul><!--kg-card-end: html--><h2 id="my-bitcoin-transaction-is-stuck-and-unconfirmed">My Bitcoin Transaction is Stuck and Unconfirmed</h2><p>You were expecting your bitcoin transaction to get mined and confirmed within the next block (~10 minutes), but for some reason your transaction isn’t going through. </p><p>It seems stuck and you’re worried that your transaction will never clear. You ask yourself, <strong>“have I just lost some bitcoin?”</strong></p><figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2020/12/image.png" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://bitcoinbriefly.com/content/images/size/w600/2020/12/image.png 600w, https://bitcoinbriefly.com/content/images/2020/12/image.png 680w"></figure><p><strong>If this sounds familiar, don’t worry - your funds are safe. Chances are, the fee you included in your transaction wasn’t high enough for miners to prioritize it.</strong></p><h2 id="how-do-miners-prioritize-transactions">How Do Miners Prioritize Transactions?</h2><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/My0y_ScfCAWt_Qy46GjXRhNe3zyVjWNBVOYN8QFqfV0Fv652eWM1_ZL5FRtu780IXcCmkl5VzHaEGp88PLIWF4m4yJCBaZt4Hi_uVIzvxV5xEOXQptFEfEz1hG2fWWFzlXNZG8HQ" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..."><figcaption>TxStreet.com’s Mempool Visualizer: Transactions with higher fee rates are prioritized by miners</figcaption></figure><p>A lot of people transact on the Bitcoin network, but each block can only fit so many transactions - <strong>the supply of block space is limited but demand for it is high.</strong></p><p>Because miners can’t fit everyone’s transactions into the next block, <strong>they prioritize transactions based primarily on transaction fee rates</strong> (though other factors like the age of the transaction and its size are also considered). </p><p><strong>If your transaction fee rate is higher than others’, then your transaction is more likely to be added and confirmed (“sent” or “unstuck”) in the next mined block.</strong> </p><p>However, in your case, your fee rate was likely not high enough...</p><h2 id="but-i-didn-t-even-set-the-fee-rate-it-was-done-automatically-by-my-wallet-">But I didn’t even set the fee rate - it was done automatically by my wallet.</h2><p>Wallets estimate fee rates the best they can... but when the<strong> network suddenly gets clogged</strong> with a ton of unconfirmed transactions, <strong>oftentimes those estimated fee rates aren’t competitive enough.</strong></p><p>As a result, you’re left in this situation where you didn’t include a high enough fee rate and your transaction is forever pending.</p><h2 id="so-then-where-in-the-queue-is-my-transaction">So then where in the queue is my transaction?</h2><p>To answer this, we need to look at the memory pool (or mempool for short). </p><p><strong>The mempool is essentially where unconfirmed transactions wait in line to get mined</strong>. There are many mempool visualizers and fee estimators, like:</p><ul><li><a href="https://jochen-hoenicke.de/queue/#1,24h">https://jochen-hoenicke.de/queue/#1,24h</a></li><li><a href="https://mempool.space/">https://mempool.space/</a></li><li><a href="https://txstreet.com/">https://txstreet.com/</a></li><li><a href="https://whatthefee.io/">https://whatthefee.io/</a></li></ul><p><em>Side note: I've also created a full guide on <a href="https://bitcoinbriefly.com/how-to-use-mempool-space-block-explorer/">how to use Mempool.space</a>.</em></p><p>Let’s look at this example from the Jochen mempool visualizer:</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh5.googleusercontent.com/7yStY1XJHr0x9JboywW79xKY30PajJw85ORtnXSY04Q7V6cT6hWkD1611PITTXTyCk0QGS3jo5DRR0CURMiKj4XOQIp969FKLY53S-87pXAOD_sQtqAw27staZsKfIu7jyPYOrl9" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..."><figcaption>Jochen-Hoenicke’s Bitcoin Mempool Visualizer</figcaption></figure><p>It looks like a mountain with peaks and valleys right? Well if we extend that analogy further:</p><ul><li><strong>A peak represents an increase in the number of unconfirmed transactions</strong>. This means that the demand for block space is greater and <strong>you’ll need to pay a higher fee rate to get your transaction confirmed ASAP</strong></li><li><strong>A valley represents a decrease</strong> in the number of unconfirmed transactions - you can pay a smaller fee rate to get your transaction confirmed</li></ul><h2 id="what-do-the-different-colored-layers-in-the-mempool-visualizer-represent">What do the different colored layers in the mempool visualizer represent?</h2><p>In the legend above, you’ll see that <strong>colors represent transaction fee rates</strong> measured in <strong>sats/byte</strong>.</p><p>Similar to how a neighborhood’s home prices are compared by cost-per-square-foot, miners compare transactions in the mempool on a<strong> Satoshis per Byte (sats/byte)</strong> basis. </p><p>You may have also seen the metric “<strong>Satoshis per Virtual Byte” (sats/vbyte) </strong>used as well. It’s a similar concept, but measures the block not in terms of its size, but in terms of its <em><strong>virtual size</strong></em>. </p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/Xlp7Ygf6v3lF4-0g5XedYXmlnPLcIAs1faloc2w6gi0VNz2TaJK_iQRdxy2kLejLOam2E0FV5OkVsRr9zqmlJloVdttZ9XVyqoAAmWC-ncLV0DhYUZQNL-YmM06Egx3ByHjFMaIB" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..."><figcaption>Mempool.space - sat/vByte fee rates</figcaption></figure><p>This sats/byte vs. sats/vbyte topic warrants its own blog post, but the gist is that one of Bitcoin’s scaling solutions, the Segregated Witness (<strong>SegWit</strong>) softfork, allows for a block to no longer be limited to its size limit of 1mb, but instead to its weight limit of 4mb. </p><p>Virtual bytes (vbytes) are essentially a conversion tool<strong> </strong>that helps us measure weight units back to size (by dividing the weight units by 4). </p><p>Regardless, <strong>the fee rate (measured in either sats/byte or sats/vbyte) helps miners prioritize a large backlog of transactions. </strong>By creating a market for a Bitcoin block’s digital real estate, miners can easily assess how your transaction fee rate stacks up against others and prioritize accordingly.<strong> </strong></p><p><strong>The higher your relative fee rate vs. other transactions’ fee rates </strong><br><strong>→ the more attractive your transaction is to mine </strong><br><strong>→ the greater likelihood of your transaction getting mined ASAP </strong><br></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh5.googleusercontent.com/XWcmH0OkoJkhMbRoDaqpgMFH6M7tFAuY5Fw_4vW2fN4qjKNnzuaLTgp3l4weiVIOv_vUd7XaQEiFzio5fX6qI4GAK_6n7XLUDm75UGyKgVN4GHJBiFiIa4HwhSlp9j98di2MOG6p" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..."><figcaption>Miners prioritize transactions like it's an auction, favoring higher-priced bids</figcaption></figure><p>Let’s say that the price of bitcoin is $20,000. There are 100,000,000 satoshis per bitcoin. A 10 sats/byte fee rate would be the equivalent of paying $0.002 per byte. If the average transaction size is <a href="https://bitcoinops.org/en/tools/calc-size/">about 250 bytes</a>, then at a 10 sat/byte fee rate, you’d pay $0.50 for your transaction.</p><ul><li>10 satoshis / 100,000,000 satoshis = 0.0000001</li><li>0.0000001 * $20,000 = $0.002</li><li>$0.002 * 250 bytes = $0.50</li></ul><p>So now that we understand the mempool dynamics and fee rate market, we can get a better idea of what the actual mempool graph means:</p><h2 id="reading-the-mempool">Reading the Mempool</h2><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/9Hj2HgWA9ImibsWWABEgft8xh3o9YD3zWivsZkWPTTGiip1FvCa_bbJVYa3dNbEXTUMofZ0XNgBH6Aw4GlaErQz7qHBcIcsvVlkIE9QsZRuFMCroV6Q5D7k2B8t-IpJ1Zo8-Tgxu" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..."><figcaption>Another Jochen Hoenicke Bitcoin Mempool Visualizer Example</figcaption></figure><p>Initially (before the left red arrow), transactions could be confirmed fairly inexpensively (blue 0-10 sats/byte; green 10-40 sats/byte) because the queue of unconfirmed transactions was really small. There wasn’t a lot of demand for block space so you could pay a lower fee rate and your transaction would confirm quickly. </p><p>Then as the mempool began to get clogged with more transactions (after the left red arrow), miners started getting overwhelmed. As demand for block space increased (ie. more transactions were being initiated and awaiting confirmation) while the supply of block space remained the same, the transaction fee rate had to increase as well (mountain peaking).</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2020/12/image-1.png" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://bitcoinbriefly.com/content/images/size/w600/2020/12/image-1.png 600w, https://bitcoinbriefly.com/content/images/2020/12/image-1.png 621w"><figcaption>Basic supply and demand dynamics: fixed supply + increasing demand = higher price</figcaption></figure><p>This led miners to prioritize transactions with higher fee rates (yellow 40-140 sats/byte) over the ones with lower fee rates (green, blue). Visually, it’s like miners focused on and started picking away at the peak of the mountain.</p><p>As the number of transactions being sent started cooling off and miners dealt with the higher fee rate transactions, they could finally return to mining the lower priority transactions with lower fee rates (after the right red arrow).</p><p>Putting this mempool and fee rate knowledge into context -<strong> if your transaction got stuck, it’s likely because you initiated your transaction right before a sudden spike in network activity</strong> (like at the left red arrow). </p><p><em>Side note: you may have also noticed a dark border covering the entire chart - this means that people were willing to pay &gt;2,000 sats/byte regardless of network conditions!</em></p><h2 id="getting-an-eta-for-your-bitcoin-transaction">Getting an ETA for your Bitcoin Transaction</h2><p>To better understand <strong>when your unconfirmed transaction will be unstuck</strong>, you’ll have to look at:</p><ol><li><strong><strong><strong>The trend of unconfirmed transactions in the mempool and</strong></strong></strong></li><li><strong><strong><strong>Determine whether the fee rate you paid will be enough to incentivize miners to mine your transaction within your preferred time horizon</strong></strong></strong></li></ol><p>Once you know what fee rate you paid and where the mempool is trending, you can get a better sense of when your transaction is likely to be confirmed.</p><figure class="kg-card kg-image-card"><img src="https://lh6.googleusercontent.com/9Hj2HgWA9ImibsWWABEgft8xh3o9YD3zWivsZkWPTTGiip1FvCa_bbJVYa3dNbEXTUMofZ0XNgBH6Aw4GlaErQz7qHBcIcsvVlkIE9QsZRuFMCroV6Q5D7k2B8t-IpJ1Zo8-Tgxu" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..."></figure><p>Returning back to this example: if you sent your transaction at the left red arrow at a 10 sat/byte fee rate (blue), then by the right red arrow, your transaction probably still hasn’t been confirmed and will likely take more time to be mined. </p><p>However, if you sent your transaction at the left red arrow at a 30 sats/byte fee rate (green), then there is a good chance that by the right red arrow, your transaction has confirmed or will be confirmed soon, assuming that no spike in network activity occurs.</p><h2 id="where-can-i-see-what-fee-rate-i-paid-for-my-transaction">Where can I see what fee rate I paid for my transaction?</h2><p>In most wallets, you’ll be able to see what fee rate you paid in your transaction details. But in case yours doesn’t, you can view these kinds of details in a <strong>block explorer</strong>.</p><p>There are many block explorers, like</p><ul><li><a href="https://mempool.space/">https://mempool.space/</a></li><li><a href="http://blockstream.info/">https://blockstream.info/</a></li><li><a href="https://www.blockchain.com/explorer">https://www.blockchain.com/explorer</a></li><li><a href="https://btc.com/">https://btc.com/</a> </li></ul><p><em>Side Note: I've also created a <a href="https://bitcoinbriefly.com/how-to-use-mempool-space-block-explorer/">full guide on how to use mempool.space</a>.</em></p><p><strong>It’s like viewing a shipped order on Fedex</strong>. On Fedex, you can enter your tracking number and you’ll see all the details regarding your package, like when it shipped, when it’s estimated to be delivered, how much you paid for shipping, confirmation of delivery, etc. </p><p>Similarly, a block explorer takes in data like a transaction ID, hash, address, block height, etc. and displays details like the transaction amount, fee rate, ETA, number of confirmations, <a href="https://bitcoinbriefly.com/practical-guide-bitcoin-addresses-explained/">addresses involved</a>, etc.</p><figure class="kg-card kg-gallery-card kg-width-wide kg-card-hascaption"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-20-at-5.01.11-PM.png" width="944" height="1232" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://bitcoinbriefly.com/content/images/size/w600/2020/12/Screen-Shot-2020-12-20-at-5.01.11-PM.png 600w, https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-20-at-5.01.11-PM.png 944w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-20-at-5.01.47-PM.png" width="1141" height="816" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://bitcoinbriefly.com/content/images/size/w600/2020/12/Screen-Shot-2020-12-20-at-5.01.47-PM.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2020/12/Screen-Shot-2020-12-20-at-5.01.47-PM.png 1000w, https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-20-at-5.01.47-PM.png 1141w" sizes="(min-width: 720px) 720px"></div></div></div><figcaption>Blockstream.info , Mempool.space Bitcoin Block Explorers</figcaption></figure><p>Comfort with a block explorer is incredibly useful and you can even <a href="https://github.com/janoside/btc-rpc-explorer">host your own</a> if you’re privacy-conscious (remember, if you’re typing super unique info like your address or transaction ID into an online service, they can correlate that information with your IP address). </p><p>Ok, so now you understand:</p><ol><li><strong>how miners prioritize transactions by fee rate</strong> and that the Bitcoin network is just functioning as expected,</li><li><strong>where your transaction stands in the queue</strong> by using tools like a mempool visualizer and block explorer, and</li><li><strong>your transaction’s expected ETA</strong> for its first confirmation by looking at the mempool trend and how your fee rate fits into that…</li></ol><h2 id="so-what-can-i-do-for-my-unconfirmed-transaction">So what can I do for my unconfirmed transaction?</h2><p>Ask yourself: how important is the speed of confirmation for your transaction?</p><p>Depending on your time horizon, you can either:</p><ol><li><strong><strong><strong>Wait it out if you have the time </strong></strong></strong>or</li><li><strong><strong><strong>Rebroadcast your transaction with a higher fee if you’re in a rush</strong></strong></strong></li></ol><h3 id="waiting-it-out-">Waiting it out:</h3><p>If your transaction isn’t time sensitive and you can wait a while, then you may want to consider just waiting for your transaction to confirm. <strong>In most cases, transactions confirm within 72 hours.</strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://images.unsplash.com/photo-1471560090527-d1af5e4e6eb6?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDF8fGNoaWxsfGVufDB8fHw&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2000" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://images.unsplash.com/photo-1471560090527-d1af5e4e6eb6?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDF8fGNoaWxsfGVufDB8fHw&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=600 600w, https://images.unsplash.com/photo-1471560090527-d1af5e4e6eb6?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDF8fGNoaWxsfGVufDB8fHw&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=1000 1000w, https://images.unsplash.com/photo-1471560090527-d1af5e4e6eb6?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDF8fGNoaWxsfGVufDB8fHw&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=1600 1600w, https://images.unsplash.com/photo-1471560090527-d1af5e4e6eb6?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDF8fGNoaWxsfGVufDB8fHw&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2400 2400w" sizes="(min-width: 720px) 720px"><figcaption>Photo by <a href="https://unsplash.com/@drewcoffman?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Drew Coffman</a> / <a href="https://unsplash.com/?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Unsplash</a></figcaption></figure><p>If your transaction doesn’t confirm within 72 hours, then don’t worry - your transaction won’t be stuck forever. After 2 weeks, it’s likely that your transaction will just be dropped from the mempool, in effect “refunding” you and allowing you to send a new transaction with your original balance (in reality, if your transaction hasn't been confirmed, your funds have never left your wallet). </p><p>If you can’t wait 72 hours to 2 weeks, then consider...</p><h3 id="rebroadcasting-your-transaction-with-a-higher-fee-">Rebroadcasting your transaction with a higher fee:</h3><p><strong>If you’re in a hurry</strong>, then you <em>might</em> have the option to rebroadcast your transaction with a higher fee (aka. <strong><a href="https://bitcoinops.org/en/scaling/fee-bumping/">Fee Bumping</a></strong>). </p><p>But this <a href="https://bitcoinops.org/en/topics/replace-by-fee/"><strong>Replace By Fee (RBF)</strong></a> technique only works with a handful of wallets - so you’ll need to check with your wallet vendor to see whether it’s compatible. You can also check this <a href="https://bitcoinops.org/en/compatibility/#replace-by-fee-rbf">compatibility matrix</a> for convenience. </p><p>If your wallet supports RBF and you have already opted-in, then you can simply send another RBF transaction. </p><p><em>Side Note: There are also “free” transaction accelerator services, but I am personally skeptical of these. Why would a free service offer to pay a higher fee on my behalf? Probably because they want to link my transactions to my IP address or something…</em></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://images.unsplash.com/photo-1520697830682-bbb6e85e2b0b?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDE3fHxzcHl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2000" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://images.unsplash.com/photo-1520697830682-bbb6e85e2b0b?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDE3fHxzcHl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=600 600w, https://images.unsplash.com/photo-1520697830682-bbb6e85e2b0b?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDE3fHxzcHl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=1000 1000w, https://images.unsplash.com/photo-1520697830682-bbb6e85e2b0b?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDE3fHxzcHl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=1600 1600w, https://images.unsplash.com/photo-1520697830682-bbb6e85e2b0b?crop=entropy&amp;cs=tinysrgb&amp;fit=max&amp;fm=jpg&amp;ixid=MXwxMTc3M3wwfDF8c2VhcmNofDE3fHxzcHl8ZW58MHx8fA&amp;ixlib=rb-1.2.1&amp;q=80&amp;w=2400 2400w" sizes="(min-width: 720px) 720px"><figcaption>Photo by <a href="https://unsplash.com/@bernardhermant?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Bernard Hermant</a> / <a href="https://unsplash.com/?utm_source=ghost&utm_medium=referral&utm_campaign=api-credit">Unsplash</a></figcaption></figure><h2 id="what-does-an-rbf-transaction-look-like">What does an RBF transaction look like?</h2><p>It looks exactly like any other transaction - you set the amount you want to send, the address of the recipient, etc. And with your newfound knowledge of mempool dynamics and fee rates, you could customize your RBF transaction’s fee rate too. </p><p>But what sets RBF transactions apart is that <strong>it tries to front run your pending transaction by incentivizing miners with a new transaction that spends the same coins but with a higher fee rate. </strong></p><p><strong>Once your new RBF transaction is mined, it essentially cancels out your original unconfirmed transaction.</strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-29-at-5.31.57-PM.png" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..."><figcaption>Bitcoin Briefly: RBF Transaction Miner Meme</figcaption></figure><p>To bring this all back into context, I’ll walk through an example.</p><h2 id="walking-through-a-replace-by-fee-rbf-transaction">Walking through a Replace By Fee (RBF) Transaction</h2><p>Though there are <a href="https://en.bitcoin.it/wiki/Replace_by_fee">different variants of RBF</a>, I'll be focusing on <a href="https://github.com/bitcoin/bips/blob/master/bip-0125.mediawiki"><strong>Opt-in RBF</strong></a><strong> </strong>(BIP 125) in this example with the Blockstream Green iOS Mobile App.</p><p>From looking at the mempool, I know that the suggested fee rate is 5-9 sats/vbyte:</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-30-at-8.04.31-AM.png" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..."><figcaption>Mempool.space: Suggested Fee Rates</figcaption></figure><p>And looking at the mempool chart, I can see that the highest priority transactions have fee rates of 2-30 sats/vbyte (purple to yellow peaks on the right-hand side), whereas most unconfirmed transactions have fee rates of 1 sat/vbyte (pink). </p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-30-at-8.04.41-AM.png" class="kg-image" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://bitcoinbriefly.com/content/images/size/w600/2020/12/Screen-Shot-2020-12-30-at-8.04.41-AM.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2020/12/Screen-Shot-2020-12-30-at-8.04.41-AM.png 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2020/12/Screen-Shot-2020-12-30-at-8.04.41-AM.png 1600w, https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-30-at-8.04.41-AM.png 2165w" sizes="(min-width: 720px) 720px"><figcaption>Mempool.space: Unconfirmed transaction backlog in the mempool</figcaption></figure><p>For this example, I've sent an initial transaction with a low 1 sat/vbyte fee rate:</p><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-30-at-8.25.49-AM.png" width="497" height="1078" alt="So Your Bitcoin Transaction Is Stuck..."></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-30-at-8.26.16-AM.png" width="542" height="1173" alt="So Your Bitcoin Transaction Is Stuck..."></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-30-at-8.27.05-AM.png" width="521" height="1130" alt="So Your Bitcoin Transaction Is Stuck..."></div></div></div></figure><p>So my 1 sat/vbyte transaction has been broadcasted and is awaiting confirmation - I can click on "View in Explorer" in the Blockstream Green app and it will open the Blockstream.info block explorer. </p><p><strong>Because I only sent a fee rate of 1 sat/vbyte and the mempool looks like miners are prioritizing 9+ sat/vbyte fee rates, I'll need to use replace-by-fee in order to get my transaction unstuck and confirmed. </strong></p><p>To do that, all I need to do is go back to my transaction details, click <strong>"Increase Fee", then set a new custom fee rate</strong> (I'll use 10 sats/vbyte this time):</p><figure class="kg-card kg-gallery-card kg-width-wide"><div class="kg-gallery-container"><div class="kg-gallery-row"><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2020/12/IMG_2445_d.png" width="1125" height="2436" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://bitcoinbriefly.com/content/images/size/w600/2020/12/IMG_2445_d.png 600w, https://bitcoinbriefly.com/content/images/size/w1000/2020/12/IMG_2445_d.png 1000w, https://bitcoinbriefly.com/content/images/2020/12/IMG_2445_d.png 1125w" sizes="(min-width: 720px) 720px"></div><div class="kg-gallery-image"><img src="https://bitcoinbriefly.com/content/images/2020/12/IMG_2456-2.PNG" width="1125" height="2436" alt="So Your Bitcoin Transaction Is Stuck..." srcset="https://bitcoinbriefly.com/content/images/size/w600/2020/12/IMG_2456-2.PNG 600w, https://bitcoinbriefly.com/content/images/size/w1000/2020/12/IMG_2456-2.PNG 1000w, https://bitcoinbriefly.com/content/images/2020/12/IMG_2456-2.PNG 1125w" sizes="(min-width: 720px) 720px"></div></div></div></figure><p><strong>So with this new fee, I expect my new RBF transaction (10 sat/vbyte) to "front-run" my initial unconfirmed transaction (1 sat/vbyte). The initial fee will be recovered and the RBF fee will be the one I pay to miners.</strong></p><p>And that's all you need to do to RBF. Easy right? </p><h2 id="wrapping-up">Wrapping Up</h2><p>So we’ve learned about:</p><ol><li>Miner incentives and transaction priority based on fee rates</li><li>The mempool and where your unconfirmed transaction is in the queue</li><li>Block explorers and transaction details</li><li>The optimal fee rate to pay to get your transaction mined ASAP</li><li>Time preference and either waiting it out or replacing by fee</li></ol><p>If you’d like to practice setting fee rates and sending RBF transactions, I’d highly recommend going through the process of inspecting the mempool and sending transactions. </p><p>With this knowledge and some practice, sending Bitcoin transactions should induce much less anxiety and instill much more confidence. </p><h2 id="other-techniques-to-reduce-transaction-fees-and-further-fee-optimization">Other Techniques to Reduce Transaction Fees and Further Fee Optimization</h2><p>So now that you’re an expert on mempool mining dynamics and fee rates, what other areas should you know about to optimize your fee rates?</p><ol><li><strong>Transaction size and complexity</strong>: did you know you can decrease the size of your transaction and pay way less in total fees by using SegWit addresses that start with ‘bc1’ instead of a ‘1’ or ‘3’?</li><li><strong>Bull markets</strong>: often times, bull markets cause a ton of network congestion so if you’re looking to transact at a lower fee rate, avoid sending transactions during bull markets</li><li><strong>9AM EST</strong>: did you know that BitMEX (one of the largest Bitcoin derivatives exchanges) usually clogs the mempool with a ton of transactions at 9AM EST every day? Best to avoid sending transactions at this time</li><li><strong>Lower time preference</strong>: if you want to optimize fee rates to a point where you pay only 1 sat/vbyte, then you and your recipient will have to lower your time preferences and practice patience ;)</li><li><a href="https://bitcoinops.org/en/scaling/payment-batching/"><strong>Batching</strong></a>: you can send bitcoin to multiple recipients in a single transaction</li><li><a href="https://en.bitcoin.it/wiki/Techniques_to_reduce_transaction_fees#Consolidation"><strong>Consolidation</strong></a>: you can consolidate your bitcoins (UTXOs) so that your future transactions use fewer inputs, decreasing your future transaction sizes</li><li><a href="https://bitcoinops.org/en/topics/cpfp/"><strong>Child pays for parent transactions (CPFP)</strong></a>: your “child” transaction can pay for both its own and its parent’s transaction so that both transactions can be confirmed in the next block</li><li><strong>Lightning Network</strong>: this second-layer scaling solution allows you to send transactions in fractions of a second and pay tiny fees, but requires much more knowledge (eg. HTLCs, state channels, channel management, etc.)</li><li><strong>Weekends</strong>: typically, fee rates are lower on weekends due to less on-chain activity</li></ol><p>Feel free to read <a href="https://en.bitcoin.it/wiki/Techniques_to_reduce_transaction_fees">this wiki</a> on other ways to reduce your future transaction fees!</p><hr><p>Hope you found this blog post helpful - if you did, please share the article to those who might need it and make sure to subscribe to the newsletter to stay up to date on the latest posts!</p><!--kg-card-begin: html--><iframe src="https://bitcoinbriefly.substack.com/embed" width="480" height="320" style="border:1px solid #EEE; background:white;" frameborder="0" scrolling="no"></iframe><!--kg-card-end: html--><p>What did I miss? What else would you like to learn more about? Let me know on <a href="https://t.me/itsminawhile">Telegram</a>!</p>]]></content:encoded></item><item><title><![CDATA[21 Million Bitcoin]]></title><description><![CDATA[Everyone has heard that Bitcoin’s supply is capped at 21 million bitcoins, but not as many people understand: Why and how it’s fixed; Why it’s specifically fixed at 21 million; When the supply cap is expected to be reached; and what happens after it hits the supply cap.

Read on to find out]]></description><link>https://bitcoinbriefly.com/21-million-bitcoin/</link><guid isPermaLink="false">5fdc99e18476b84d44a8a169</guid><category><![CDATA[Explainers]]></category><category><![CDATA[History]]></category><dc:creator><![CDATA[Alex Min]]></dc:creator><pubDate>Sat, 19 Dec 2020 14:59:25 GMT</pubDate><media:content url="https://bitcoinbriefly.com/content/images/2021/03/emily-morter-8xAA0f9yQnE-unsplash.jpg" medium="image"/><content:encoded><![CDATA[<img src="https://bitcoinbriefly.com/content/images/2021/03/emily-morter-8xAA0f9yQnE-unsplash.jpg" alt="21 Million Bitcoin"><p>Published: 2020-12-19 at block 662,061<br>Bitcoin Price: $23,300</p><h3 id="table-of-contents">Table of Contents</h3><!--kg-card-begin: html--><ul>
    <li><a href="#21-million-bitcoin">21 Million Bitcoin</a></li>
    <li><a href="#why-and-how-is-bitcoin-s-supply-fixed">Why and How Is Bitcoin’s Supply Fixed?</a></li>
    <li><a href="#why-21-million-bitcoin">Why 21 Million Bitcoin?</a></li>
    <li><a href="#when-will-the-bitcoin-supply-reach-21-million">When Will The Bitcoin Supply Reach 21 Million?</a></li>
    <li><a href="#what-happens-when-bitcoin-reaches-21-million">What Happens When Bitcoin Reaches 21 Million?</a></li>
</ul><!--kg-card-end: html--><h2 id="21-million-bitcoin">21 Million Bitcoin</h2><p>Everyone has heard that Bitcoin’s supply is capped at 21 million bitcoins, but not as many people understand:</p><ul><li>Why and how it’s fixed</li><li>Why it’s specifically fixed at 21 million</li><li>When the supply cap is expected to be reached</li><li>and what happens after it hits the supply cap</li></ul><p>I answer these questions in this blog post by diving into topics like the predictable issuance schedule; purchasing power; the world’s M1 money supply; Bitcoin’s security budget; BIP 42, and more.</p><h2 id="why-and-how-is-bitcoin-s-supply-fixed">Why and How Is Bitcoin’s Supply Fixed?</h2><p>Whether from his <a href="https://bitcointalk.org/index.php?topic=238.msg2004#msg2004">old forum posts</a> or the message he encoded into the <a href="https://en.bitcoin.it/wiki/Genesis_block">genesis block</a>, many believe that Satoshi <strong>fixed the supply of Bitcoin in response to centrally-managed, inflationary monetary policies</strong> (like quantitative easing and fractional-reserve banking).</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/yflYt--S5rCB9-ItwYgMGsl_tVnBpHth_nhokUYz27NSeLBS8OIJnzgr8VQIL8rxSI-VdjgXCJ3-QPsVPmqyip8dcgTUpstzOIJEUeyUe3HFl0jBaJKrb4gYTmEk_wFaxcc2InAA" class="kg-image" alt="21 Million Bitcoin"><figcaption>Bitcoin Genesis Block: The Times 03/Jan2009 Chancellor on brink of second bailout for banks</figcaption></figure><p>To “escape the arbitrary inflation risk of centrally managed currencies,” Bitcoin had to be designed as a network of rules, not rulers. So Satoshi created a bunch of rules before launching the network, which resulted in Bitcoin’s fixed supply: </p><p>One of Bitcoin’s rules is its predetermined inflation rate - ie. how many bitcoins will be created and at what rate. It says that initially, (1) Bitcoin will mint 50 new bitcoins every block (~10 minutes), and (2) every 210,000 blocks (~4 years), the number of bitcoins minted every block will halve (eg. from 50 to 25). <strong>This rule explains why Bitcoin’s supply is fixed and allows us to extrapolate the total number of bitcoins to ever be mined at approximately 21 million. </strong>If you’d like to learn more about this rule, you may want to look up terms like: the subsidy halving, issuance schedule, predictable inflation algorithm, disinflation, mining schedule, etc.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/rBa3Z1WsPyvhF1IDkW4H9n4naV96nv4mC55HcoYD8ySeEKKNQudwYIrNGMHBG6buPaEA6KlAh8CDkhRninBs0EkcuVnzZjoWae217R0TaUKWOdNxp4mmOyeZL4JnqUtZInRle3mm" class="kg-image" alt="21 Million Bitcoin"><figcaption>Bitcoin's Controlled Supply and Issuance Schedule (<em>Source: </em><a href="https://en.bitcoin.it/wiki/Controlled_supply"><em>https://en.bitcoin.it/wiki/Controlled_supply</em></a><em>)</em></figcaption></figure><p>Another rule is that any change to Bitcoin’s rules can only be accepted if the majority of network participants (like miners, full node operators, businesses, developers, etc.) agree, adopt, and enforce the rule change. This “meta” rule helps the network enforce the 21 million fixed supply: <strong>if a central bank wanted to increase the 21 million supply cap or change Bitcoin’s monetary policy in any other way, they would only be able to do so with the majority of the network’s permission. </strong>On the other hand, if an actor tried to increase the supply limit without the majority consensus, peers in the Bitcoin network would simply reject that action as invalid because it doesn’t adhere to the rules. </p><p>Put simply, rule #1 is to adhere to the issuance schedule and rule #2 is to adhere to rule #1 (among other rules).</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/AyIFsAbENkdvyaomIx2d7MfIeAdATV9Nb_ypgYqZGsy_E8E-vVZBZ3PhUOP0qM_sTR3linDx9SiEitViO8w_1GMAypuu9s0eSll7lGCkfSYj_hYnQH65wYKeMltQkoll01G3GZ6E" class="kg-image" alt="21 Million Bitcoin"><figcaption><em>Bitcoin’s Rules, Represented By Tim Duncan's Block Over Russell Westbrook</em></figcaption></figure><p><strong>So in an attempt to create an alternative, disinflationary money, Satoshi created a bunch of rules that ultimately have set and enforced Bitcoin’s supply at ~21 million. </strong></p><p>As such, those who oppose the popular expansionary monetary policies employed by central banks have begun flocking over to Bitcoin. Why? Because of Bitcoin’s predictable, disinflationary issuance schedule and strongly-enforced 21 million supply. </p><p>Such proponents believe that the purchasing power of their money should increase over time rather than decrease from inflation. As believers in free markets, they expect that a fixed supply matched with increasing demand will lead to a natural increase in price.</p><p>Using the <a href="https://www.economist.com/news/2020/07/15/the-big-mac-index">Big Mac Index</a> as a proxy for the Consumer Price Index (CPI), we can see the disparity in purchasing power over time between the two assets, highlighting why so many people find Bitcoin attractive.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://bitcoinbriefly.com/content/images/2020/12/Screen-Shot-2020-12-27-at-9.35.21-AM.png" class="kg-image" alt="21 Million Bitcoin"><figcaption>As of 2020-12-27: Big Mac Index of USD vs. BTC: <em>Used New Liberty Standard Rates for 2009 BTC </em><a href="https://web.archive.org/web/20091229132610/http://newlibertystandard.wetpaint.com/page/Exchange+Rate"><em>where the first Bitcoin-USD rate was logged</em></a><em>, and estimated 2020 EOY Price</em></figcaption></figure><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/DX5qDP6PmYd-nXh-NW8wStI7zC84wM3IZwavc3VGu7tQ0eCbbZyDZSZmiluT5lJ5EtZfsdB8hkjkU1Q1G6NQRDGmEXB7x95-p0dYkB7ETQUDuCeE9dYIYYPThtmJI5_0y4YXqx3C" class="kg-image" alt="21 Million Bitcoin"><figcaption>USD Purchasing Power Over Time (<em>US Bureau of Labor Statistics (BLS) / Federal Reserve Economic Data (FRED))</em></figcaption></figure><h2 id="why-21-million-bitcoin">Why 21 Million Bitcoin?</h2><p>So Bitcoin’s supply is fixed because of its preset inflation rate and enforcement by the majority consensus. But why is it capped specifically at 21 million?</p><p>Perhaps Satoshi just picked a bunch of random numbers for the block time, satoshis per bitcoin, initial block subsidy, etc. and these factors coincidentally ended up limiting the supply of bitcoin to 21 million. </p><p>But there is strong reason to believe that the 21 million limit was the result of specific design decisions that sought to propel Bitcoin’s displacement of the world’s national currencies.</p><p>Rich Apodaca (Bitzuma) explains in a <a href="https://bitzuma.com/posts/the-21-million-bitcoin-question/">blog post</a> that to replace the world’s national currencies, Bitcoin would need to adhere to certain restrictions. It is believed that these restrictions resulted in the specific number of satoshis per bitcoin, the 210,000 block halving issuance schedule, and ultimately the 21 million supply cap. These restrictions are listed below:</p><p><strong>The number of satoshis must </strong>(1) <strong>fit within the</strong> <strong>IEEE floating point system</strong> (a computer science schema that keeps numbers precise instead of rounded, as long as the total number is under 2^53: 9 quadrillion) and (2) <strong>include a safety margin</strong>: a one-bit margin would result in the maximum threshold of 2^52 (4.5 quadrillion), and a two-bit margin would result in 2^51 (2.3 quadrillion).</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh4.googleusercontent.com/a64uVf-55So1S5buSEpLoa4NT_2uIf-eNEZZQAviWjgMp4QuGh1lPvCj0CnlnAGBe3In3k2Hm6lcVshUSewcbrFPTANibklh_8_PG6rDe7CqefRCLVDOXOuWQTr4a5i1hN7vQAW6" class="kg-image" alt="21 Million Bitcoin"><figcaption>IEEE: Wikipedia</figcaption></figure><p><strong><strong>Parity between the US Dollar and bitcoin</strong> </strong>(ie. 1 BTC = 1 USD) could be reached without spooking investors. In other words, if Bitcoin were a country, it would have one of the smallest M1s in the world if bitcoin achieved dollar parity.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/B_l2yLWYxYtbboy13_QlEsS--bv_KYie6U1lM4-6Jx8muSj1azNUuPxiFf_PD_wWdqF5_D0FS8sf2OnU_UXPIEvBBHLV4KNhmCwb9Lu7JzkdZIk656fSbLdBN3a5ORtS9w44Wn8R" class="kg-image" alt="21 Million Bitcoin"><figcaption><em>If 1 BTC = 1 USD, Bitcoin’s Market Cap Would Be One of The Smallest M1’s (M1's from CIA Factbook)</em></figcaption></figure><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh4.googleusercontent.com/ptjIyGhEFBGvmuMBPaVRExGsU_vBeJUPMWpJrXOB2ZrK819Ar4JK_1W4C-6f_oKpEBgTIEqm4X6Mfzi7mLww3C0z9Bx_twbIoAvLAsEsgELw-O4Ho-hFBxk5LwURiafA_8xlFzcR" class="kg-image" alt="21 Million Bitcoin"><figcaption><em>As of 2020-12-19, Bitcoin is the 27th largest currency (</em><a href="https://fiatmarketcap.com/"><em>fiatmarketcap.com</em></a><em>)</em></figcaption></figure><p>Furthermore, <strong>parity between the US cent and satoshi</strong> could be reached if the Bitcoin market capitalization became roughly the same as the global M1 money supply. In other words, <strong>the number of satoshis must be roughly equal to the global M1 money supply </strong>as of 2009 when Bitcoin launched, which was about 2 quadrillion US cents at the time. <strong>This restriction helped establish the 100,000,000:1 satoshi to bitcoin ratio.</strong></p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/s3lGo7MuypmdDY4uAbiw8eQYGjEHhBTSNKDBfRpSRdMRb3SqkhzH38NygA1rFpkKYKzCF9aEiFu4mDoEqag_DAVGbk4eFQdxFaV52giXij2gDqDA1HC7QOqDM2zCj0XHRrySakb5" class="kg-image" alt="21 Million Bitcoin"><figcaption><em>If 1 Satoshi = 1 US Cent, Bitcoin’s Market Cap Would Be Similar to the World’s M1 (M1's from CIA Factbook)</em></figcaption></figure><p>Also,<strong> the halving schedule should ensure that block subsidies could continue to be paid until Bitcoin has reached a critical mass of adoption, at which point transaction fees would become self-sustaining</strong>.</p><p>It seems that there were some assumptions made: there’d be 1,000 users by the end of 2009; the user base would double every year; and the maximum user base would be capped at the world population in 2009 (6.8 billion). So to hit 6.8 billion from 1,000, Bitcoin’s user base would need to double every year for 23 years. The number of halvings required to reduce the subsidy fund by 99% is 6. Dividing 24 (23 years + the 1st year) by 6 makes 4 years per halving. </p><p>So in the 7th block reward era (ie. after 6 halvings), 99% of bitcoins would be mined. And because Bitcoin makes it easier to count blocks instead of time, then each epoch would last 210,000 blocks, based on the difficulty target of producing one block every ten minutes. Starting with an initial block subsidy of 50 btc per block, this would result in the production and supply cap of 2,099,999,997,690,000 satoshis (nearly 2.1 quadrillion - a number that fits within the constraints listed above).</p><p>Finally, <a href="https://www.ofnumbers.com/2018/10/01/interview-with-ray-dillinger/">Ray Dillinger</a> (aka Cryddit, the <a href="http://diswww.mit.edu/bloom-picayune/crypto/137796">first person who commented on Satoshi’s white paper</a>) provides <a href="https://bitcointalk.org/index.php?topic=819656.msg9170781#msg9170781"><strong>anecdotal evidence</strong></a> that supports the rationale behind the 21M limit.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/OovTSpVDtqPu-JsVd5vmbWLfPe7JmCaMYiaD_EB95yktuv6rkJFXdJc-MugA2B_RWnnTQeFBBs1XvC3pJiHw2Fb8zq-HrHrshtlSOTZ9eorN0g6xkyD9vPQQed30sCO4glhD9HyT" class="kg-image" alt="21 Million Bitcoin"><figcaption><em>BitcoinTalk: Cryddit (Ray Dillinger) describes his discussions with Satoshi and Hal Finney about the 21M limit</em></figcaption></figure><p><strong>In summary, the IEEE standard, parity milestones, halving schedule, and anecdotes provide evidence behind the specific number of 21 million.</strong></p><h2 id="when-will-the-bitcoin-supply-reach-21-million">When Will The Bitcoin Supply Reach 21 Million?</h2><p>Based on Bitcoin’s difficulty adjustment algorithm and the 210,000 block (4 year) halving schedule, the Bitcoin supply is <strong>expected to be fully mined</strong> (~21 million bitcoins; more specifically 2,099,999,997,690,000 satoshis) <strong>in</strong> <strong>the year 2140</strong>. </p><p>Though 120 years may seem like a long time, other significant milestones will come much sooner:</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh5.googleusercontent.com/Xr93YKPkyF11BSxh10tT4gntL5wgF_Lj-lcXn-3jEDi2FdL_YKLhoeHg9lWt9Kx__-cstE14DbqprXtX4MS_f9w-Nvnb-N34EXblz7gFMU_RZoeJjlOZWGgMfaTRFT70NGV69Vie" class="kg-image" alt="21 Million Bitcoin"><figcaption><em>ETA for Bitcoin's Major Mining Milestones</em></figcaption></figure><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/BcStjb1QQWaKpYrgUOAiZABDDFCLT7O9lA4AQQWu1pPWIl7EEQfyfHmoi1zh7vQI8ahIL9ZeOi48zbDIO738yADfvRhVadyHFiLhkLQK7bEjoItJ9ZFEzMVzaLY4dWZ5UG3OQw_x" class="kg-image" alt="21 Million Bitcoin"><figcaption>Bitcoin's Inflation Rate (<a href="https://en.bitcoin.it/wiki/Controlled_supply"><em>https://en.bitcoin.it/wiki/Controlled_supply</em></a><em>)</em></figcaption></figure><h2 id="what-happens-when-bitcoin-reaches-21-million">What Happens When Bitcoin Reaches 21 Million?</h2><p>Every block provides miners with two streams of revenue: the block subsidy and transaction fees. When all 21 million bitcoin have been mined, mining revenue will only consist of transaction fees. <strong>Thus, transaction fees must provide enough financial incentive</strong> <strong>for miners to continue processing transactions, adding blocks to the blockchain, and securing the network. </strong></p><p>Critics claim that transaction fees won’t be enough to sustain Bitcoin and its security budget, and those concerns loom larger as we get closer to the year 2035, when 99% of bitcoins are expected to be mined. Yet, despite every halving, the network has grown more secure and Bitcoin’s sustainability through transaction fees looks more and more promising:</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/mz3YIjrXUnCGD7RBMbZihNeTn931XNF8AQZg0nL3h4vIohgNUc265we_hLqb2_8CdAAOmvwZIc8t2a7J5ZnCTddid93B5mKfnAqVddxmtinXtjATI1hoNjkjBDB5C7EfctWN4A4Z" class="kg-image" alt="21 Million Bitcoin"><figcaption><em>Analysis on Bitcoin’s Growing Network Security and Fee Sustainability Every Halving</em></figcaption></figure><p>As the subsidy continues to halve; as the price of bitcoin increases; as the Bitcoin user base grows; as the number of transactions increases; as demand for block space grows; as more miners compete to earn bitcoins; as the hashrate increases; etc.... We can expect Bitcoin transaction fees to not only represent a greater percentage of the total block reward but also continue to incentivize miners to secure the network.</p><p>For further reading on this topic, I’d recommend Dan Held’s <a href="https://medium.com/@danhedl/bitcoins-security-is-fine-93391d9b61a8">blog post</a> on Bitcoin’s Security Budget.</p><h3 id="fun-fact">Fun Fact </h3><p>When Bitcoin went live, Satoshi unintentionally introduced a bug that would re-issue a new supply of 21 million bitcoins every 64 block halvings. The effect was similar to discovering a new gold mine every ~250 years. Though parameters like the inflation schedule were expected to cap the supply to 21 million, the bug would over-shift these values causing the supply to actually inflate forever.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh5.googleusercontent.com/vuku0HpUSSvJOEI2S2FAdFkEUnuHEEWh63yJj_y1lqKKOn1BJJiRNZcKvhEmsG4GQ-RgMcx4zeEulgLdXRhr89uu_D4u1aDz7e4wuDzGNnJ6uk3ZZTmEf1BA8Qj9i9zAouIJqyrX" class="kg-image" alt="21 Million Bitcoin"><figcaption><em>The Inflation Bug Fixed by BIP 42: </em><a href="https://github.com/bitcoin/bips/blob/master/bip-0042.mediawiki"><em>https://github.com/bitcoin/bips/blob/master/bip-0042.mediawiki</em></a></figcaption></figure><p>It wasn’t until 2014 that <a href="https://github.com/bitcoin/bitcoin/pull/3842">ditto-b noticed the bug</a>. The Core developers used the opportunity to package up an elaborate April Fool’s joke and fix in <a href="https://github.com/bitcoin/bips/blob/master/bip-0042.mediawiki">BIP 42</a>. As prolific core developer Pieter Wuille <a href="https://www.reddit.com/r/Bitcoin/comments/94r41n/satoshi_did_not_propose_the_21_million_setsupply/">explains</a>, “it claims (jokingly) that Bitcoin was designed to look like it had a 21 million limit, but through underhanded programming didn't actually do that.” </p><p>BIP 42 is a backwards-compatible fix, encouraging miners to take a lower subsidy than the max after the 64th block reward halving. If instead, a miner chooses to consume 100% of the max subsidy, they will be forked from the network. </p><p>Interested in learning more about Bitcoin’s history of bugs? Check out the blog post <a href="https://bitcoinbriefly.com/hacking-bitcoin-history-of-bitcoin-hacks/">Hacking Bitcoin: A History of Bitcoin Hacks</a>. </p><hr><p>Hope you found this blog post insightful - if you did, make sure to subscribe to the newsletter to stay up to date on the latest posts!</p><!--kg-card-begin: html--><iframe src="https://bitcoinbriefly.substack.com/embed" width="480" height="320" style="border:1px solid #EEE; background:white;" frameborder="0" scrolling="no"></iframe><!--kg-card-end: html--><p></p><p>What else would you like to learn more about? Let me know on <a href="https://t.me/itsminawhile">Telegram</a>!</p>]]></content:encoded></item><item><title><![CDATA[How to Hack Bitcoin: A History of Bitcoin Hacks]]></title><description><![CDATA[Bitcoin has been "hacked" in the past... will it continue to be vulnerable moving forward? Learn more about Bitcoin's history and future of bug exploits.]]></description><link>https://bitcoinbriefly.com/hacking-bitcoin-history-of-bitcoin-hacks/</link><guid isPermaLink="false">5fcb8ca08476b84d44a8a0b5</guid><category><![CDATA[History]]></category><dc:creator><![CDATA[Alex Min]]></dc:creator><pubDate>Sat, 05 Dec 2020 14:30:00 GMT</pubDate><media:content url="https://bitcoinbriefly.com/content/images/2021/03/neonbrand-dDvrIJbSCkg-unsplash.jpg" medium="image"/><content:encoded><![CDATA[<figure class="kg-card kg-image-card"><img src="https://bitcoinbriefly.com/content/images/2021/03/neonbrand-dDvrIJbSCkg-unsplash-1.jpg" class="kg-image" alt="How to Hack Bitcoin: A History of Bitcoin Hacks" srcset="https://bitcoinbriefly.com/content/images/size/w600/2021/03/neonbrand-dDvrIJbSCkg-unsplash-1.jpg 600w, https://bitcoinbriefly.com/content/images/size/w1000/2021/03/neonbrand-dDvrIJbSCkg-unsplash-1.jpg 1000w, https://bitcoinbriefly.com/content/images/size/w1600/2021/03/neonbrand-dDvrIJbSCkg-unsplash-1.jpg 1600w, https://bitcoinbriefly.com/content/images/2021/03/neonbrand-dDvrIJbSCkg-unsplash-1.jpg 1800w" sizes="(min-width: 720px) 720px"></figure><img src="https://bitcoinbriefly.com/content/images/2021/03/neonbrand-dDvrIJbSCkg-unsplash.jpg" alt="How to Hack Bitcoin: A History of Bitcoin Hacks"><p>Published: 2020-12-05 at block 660071<br>Bitcoin Price: $18,975</p><h3 id="table-of-contents">Table of Contents</h3><!--kg-card-begin: html--><ul>
    <li><a href="#hacking-bitcoin">Hacking Bitcoin</a></li>
    <li><a href="#can-bitcoin-be-hacked-has-bitcoin-been-hacked">Can Bitcoin Be Hacked / Has Bitcoin Been Hacked?</a></li>
    <li><a href="#what-is-bitcoin-s-uptime-downtime">What Is Bitcoin’s Uptime / Downtime?</a></li>
    <li><a href="#what-is-cve-2010-5139-bitcoin-s-value-overflow-incident">What Is CVE-2010-5139: Bitcoin’s Value Overflow Incident?</a></li>
	<li><a href="#what-is-cve-2013-3220-bitcoin-s-migration-from-berkeleydb-to-leveldb-incident">What is CVE-2013-3220: Bitcoin’s Migration From BerkeleyDB to LevelDB Incident?</a></li>
    <li><a href="#what-is-cve-2018-17144-cve-2018-17145-bitcoin-s-inventory-out-of-memory-denial-of-service-inflation-bug-vulnerability">What is CVE-2018-17144 / CVE-2018-17145: Bitcoin’s Inventory Out-of-Memory Denial-of-Service / Inflation Bug Vulnerability?
</a></li>
    <li><a href="#how-to-secure-bitcoin">How to Secure Bitcoin?</a></li>
    <li><a href="#is-bitcoin-secure">Is Bitcoin Secure?</a></li>
    <li><a href="#can-bitcoin-be-shut-down">Can Bitcoin Be Shut Down?</a></li>
    
</ul><!--kg-card-end: html--><h2 id="hacking-bitcoin">Hacking Bitcoin</h2><p>Though Bitcoin is often considered an impenetrable peer-to-peer network, it is still susceptible to “hacks”. In the past, people “hacked” Bitcoin <strong>by</strong> <strong>exploiting</strong> <strong>bugs that were introduced into the Bitcoin codebase</strong>. Such exploits have previously allowed for double spends, transaction censorship, artificial supply inflation past the 21 million cap, etc. </p><p>As the Bitcoin codebase grows in complexity, you can expect the number of bugs introduced to increase in lockstep, though rigorous review and testing certainly help mitigate their impact.</p><p>Read on to learn about the history of Bitcoin's hacks and what we can do to ensure a more secure Bitcoin network moving forward.</p><h2 id="can-bitcoin-be-hacked-has-bitcoin-been-hacked">Can Bitcoin Be Hacked / Has Bitcoin Been Hacked?</h2><p>Many mistakenly equate Bitcoin exchange hacks (like Mt. Gox, Bitfinex, etc.) to Bitcoin itself getting hacked. This is an incorrect assertion. Still, the Bitcoin network has been “hacked” in the past through other means. In <a href="https://en.bitcoin.it/wiki/Common_Vulnerabilities_and_Exposures">Bitcoin’s history of vulnerabilities</a>, there have been three major bugs,<strong> two of which were exploited and resulted in chain rollbacks</strong>:</p><ul><li>CVE-2010-5139: Bitcoin’s Value Overflow Incident (Exploited)</li><li>CVE-2013-3220: Bitcoin’s Migration From BerkeleyDB to LevelDB Incident (Exploited)</li><li>CVE-2018-17144 / CVE-2018-17145: Bitcoin’s Inventory Out-of-Memory Denial-of-Service / Inflation Bug Vulnerability</li></ul><p>Still, for a 12 year old piece of software with virtually no loss of funds, nearly 100% uptime, and a $350 billion bounty on its head (ie. the market cap as of 2020-12-05), Bitcoin is still regarded as one of the most secure networks ever created.</p><h2 id="what-is-bitcoin-s-uptime-downtime">What Is Bitcoin’s Uptime / Downtime?</h2><p><a href="https://www.buybitcoinworldwide.com/bitcoin-uptime/">Many consider</a> <strong>Bitcoin’s uptime to be 99.98%</strong> (as of 2020-12-05, Bitcoin has gone 2,826 days without downtime), with the <strong>only downtime events</strong> being related to the two exploited bugs:</p><ul><li>CVE-2010-5139: Bitcoin’s Value Overflow Incident - 8 hours and 27 minutes of downtime</li><li>CVE-2013-3220: Bitcoin’s Migration From BerkeleyDB to LevelDB Incident - 6 hours and 20 minutes of downtime</li></ul><p><a href="https://en.wikipedia.org/wiki/Uptime">Wikipedia defines uptime</a> as <em>“a measure of system reliability, expressed as the percentage of time a machine, typically a computer, has been working and available. Uptime is the opposite of downtime.” </em></p><h2 id="what-is-cve-2010-5139-bitcoin-s-value-overflow-incident">What Is CVE-2010-5139: Bitcoin’s Value Overflow Incident?</h2><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/hwEYa3tTAhjbcN0GiaBHehkEGA7Vck0cnldvTxTyXoSN9MZnET2WJm8n0p-_-u466dyJFjj8UJQLWA3Nl8YMOwrmLaVnuNg6DPPb_Y_xbuxQ6txw58a8i-HxQf3DMN8h916OhyZ_" class="kg-image" alt="How to Hack Bitcoin: A History of Bitcoin Hacks"><figcaption>Jgarzik: Strange block 74638 with Large Value Out’s - CVE-2010-5139 Bitcoin Value Overflow on BitcoinTalk</figcaption></figure><p>On August 15th 2010, <a href="https://bitcointalk.org/index.php?topic=822.0">Jeff Garzik discovered</a> in block 74,638 that an unknown entity <strong>exploited a value overflow bug in Bitcoin’s code. This allowed the attacker to create over 184 billion bitcoin</strong> amongst 3 addresses, well beyond the 21 million supply cap. This was possible because the code for checking Bitcoin transactions didn't work correctly when summing very large outputs.</p><p>Within five hours of the discovery, Satoshi Nakamoto published a new version of the Bitcoin client (0.3.10) with a fix that contained a soft fork. Network participants would soon pivot over to this new client and soft fork; by block height 74,691, they rejected the overflow transactions and adopted the “good” blockchain.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh4.googleusercontent.com/YtFiBPny4X3TtuNYVU4eJLyW4H5IVgTo4nLzMTaMvE1szOHb32h7iIspiwU_K22frCJBZfd4993DhZiwFcBsbMoustq_5ndco1vJ8ffs6Aj0o91wE5D0e0XV_6TcFKXy3XDWVCnZ" class="kg-image" alt="How to Hack Bitcoin: A History of Bitcoin Hacks"><figcaption><em>Satoshi: Patch for Value Overflow Bug on BitcoinTalk</em></figcaption></figure><p>But in doing so, the network essentially made previously-valid blocks, which included the exploited transactions, invalid. Though the community achieved social consensus on which chain to roll back to, rollbacks have received much criticism both inside and outside the Bitcoin community. The criticism stems from the implications of rollbacks, such as a revision of history, censored transactions, loss of funds, a higher likelihood for double spends, etc.</p><p>How serious was this event? The lead maintainer of the Bitcoin repository on Github, Wladimir Van Der Laan said, “<a href="https://www.coindesk.com/9-biggest-screwups-bitcoin-history">it was the worst problem ever.</a>” </p><p>However, at this stage in Bitcoin’s life, the bug was perceived more as a growing pain. The price of bitcoin would jump from ~$0.07 and hit an all-time-high of nearly $0.40 later that year.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/yAvw8PoWYTpn_3mgGs7QKGSKdxFsXMkMeA6opVey_2U2ykLwGm5F2vg55a8W2DLEx24X5uUOYtWsEvwa5uz9fZLXozm8i8KkS--7P77mHXOhUZpaJkwBEQ0BVcLQIBTvuy4Hhvcy" class="kg-image" alt="How to Hack Bitcoin: A History of Bitcoin Hacks"><figcaption><em>Bitcoin Price History in 2010 from $0.07 to $0.30, Peaking at $0.39</em></figcaption></figure><h2 id="what-is-cve-2013-3220-bitcoin-s-migration-from-berkeleydb-to-leveldb-incident">What is CVE-2013-3220: Bitcoin’s Migration From BerkeleyDB to LevelDB Incident?</h2><p>On March 11th 2013, a bitcoin miner running version 0.8.0 created a large block at height 225,430 that was incompatible with earlier versions of Bitcoin. This <strong>led to a hard fork</strong> between network participants who were running version 0.8.0 and those running older versions. During this hard fork, a non-malicious actor was able to <strong>execute a <a href="https://archive.is/64Rkj">large double spend</a></strong>, pushing Core developers to figure out the root cause. It turns out, the unplanned chain split was <strong>caused by a <a href="https://github.com/bitcoin/bips/blob/master/bip-0050.mediawiki">migration from Berkeley DB to Level DB</a></strong>, which did not implement the same locking limits.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/NBmrdt_j6jleEj_i8M0ed6_GBcKZz4qVGBTYtyUlimCZhy-zK2iP_ESgOkmpYHDAJWpml1VYXqz8SjrvlhNLIsGW8_UgBB0avhNVI2zulFjAohXkCf7l5LmDXIdlOLlITvM5_HXb" class="kg-image" alt="How to Hack Bitcoin: A History of Bitcoin Hacks"><figcaption><em>Macbook-air: Successful Double Spend against OKPAY</em></figcaption></figure><p>Large mining pool operators who were running version 0.8.0, like Marek Palatinus of Slush and Michael Marsee (Eleuthria) of BTCGuild, were asked to switch back to version 0.7. By redirecting hashpower, miners could help the network reorganize around the pre-0.8 chain (which did not include the larger block) and make all Bitcoin software compatible again. </p><p>Slush and BTCGuild quickly downgraded their nodes despite having to sacrifice significant amounts of miner revenue. During this time, deposits to major exchanges and payments via BitPay were also temporarily suspended. The network finally succeeded in its chain rollback on August 16th 2013 when block 252,451 was accepted by the main network, as noted in <a href="https://github.com/bitcoin/bips/blob/master/bip-0050.mediawiki">BIP50 - Gavin Andreesen’s post-mortem</a>. </p><p>Just like with CVE-2010-5139 (Bitcoin’s Value Overflow Incident), the Bitcoin network made previously-valid blocks invalid by rolling back to another chain, and criticisms of centralized coordination once again rose to the forefront. Still, with the crisis averted, the price of bitcoin would hit another ATH of about $1,200 later that year.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/3GO6FheDqN2BoHzs4qfX3XhtlrRvjmtzak2vOp3B6dlWP65qJGBI0BI8GD6ZSsQKepDbAZGA8F4lFMwjbpMdpPASxGmAw54babJrc1Mn1SiyfHDHBhfzdZLatVxVlD5MaMkO9-8o" class="kg-image" alt="How to Hack Bitcoin: A History of Bitcoin Hacks"><figcaption><em>Bitcoin 2013 Price Action from $13 to $757, Peaking Over $1,100</em></figcaption></figure><h2 id="what-is-cve-2018-17144-cve-2018-17145-bitcoin-s-inventory-out-of-memory-denial-of-service-inflation-bug-vulnerability">What is CVE-2018-17144 / CVE-2018-17145: Bitcoin’s Inventory Out-of-Memory Denial-of-Service / Inflation Bug Vulnerability?</h2><p>On September 17th 2018, developer Awemany (aka: Beardnboobies) <a href="https://medium.com/@awemany/600-microseconds-b70f87b0b2a6">disclosed</a> a vulnerability to Bitcoin Core developers. This vulnerability could allow a <strong>miner to double-spend bitcoins, with the potential to inflate bitcoin past the 21 million hard cap</strong>. Compared to the other bugs listed above, this one was <strong>never exploited on mainnet</strong>. But the severity of the bug was so great that Core developers initially kept it a secret, in order to fix the exploit in a timely manner.</p><p>What enabled this critical bug? In 2016, version 0.14 of Bitcoin included what seemed to be a <a href="https://github.com/bitcoin/bitcoin/pull/9049">600 microsecond optimization</a>. But the optimization removed what was believed to be a redundant check on newly-received blocks. The removal of this check introduced a denial-of-service (DoS) vulnerability that could be exploited by miners (CVE-2018-17145). This issue alone could’ve shut down a chunk of the network. </p><p>But then in 2017, another issue was introduced into the codebase. Version 0.15.0 <a href="https://github.com/bitcoin/bitcoin/pull/10195">edited code that was supposed to catch unexpected errors</a>. Instead, the change did the opposite, allowing miners to double spend bitcoin (though this was never exploited on mainnet), with the potential to inflate the supply beyond the 21 million ceiling (CVE-2018-17144). </p><p>So a day after Awemany reported the double-spend issue, Bitcoin Core developers fixed it and pushed out an update (0.16.3). However, they initially only disclosed the less serious DoS vulnerability in the release notes. Why? Because during this time, they would push businesses and miners like SlushPool to upgrade, to minimize the chance of a chain split from occurring. </p><p>They would continue to delay publication of the full issue until after the new version had both the majority of the hashrate and enough adoption by users. The developers would <a href="https://bitcoincore.org/en/2018/09/20/notice/">officially disclose</a> CVE-2018-17144 on September 20th 2018. A day later, Core developers warned users that for the following week, they should only consider transactions with <a href="https://bitcoin.org/en/alert/2018-09-21-required-upgrade">200 confirmations</a> to be irreversible, instead of the standard 6.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh6.googleusercontent.com/sU4cFB0NQ-srcMN-6lB0njtelib3mYRcxulgGZEwLwIMksOqckuCDg_SpZY1yQEl2Py5S6LpTrljnSmg7CHThBMeTsig-_lSXq5Pydgm36Te5YZRK8hBHAdteRpab4UGsUnIL5Rv" class="kg-image" alt="How to Hack Bitcoin: A History of Bitcoin Hacks"><figcaption><em>Bitcoin Core Developers Warning of a Potential Chain Split and Advising 200 Confirmations</em></figcaption></figure><p>Jimmy Song notes in <a href="https://hackernoon.com/bitcoin-core-bug-cve-2018-17144-an-analysis-f80d9d373362">his analysis of CVE-2018-17144</a> what could’ve happened if the bug was exploited:</p><ul><li>0.14.x nodes would have crashed</li><li>Older nodes and many alternative clients would have rejected that block</li><li>Many block explorers run on custom software and not core, so at least some would have rejected the block and wouldn’t have shown any transactions from that block</li><li>Depending on the software miners were running we may have ended up with a chain split.</li></ul><p><em>“Because of these irregularities, people on the network would soon have tracked this down, probably have alerted some developers and the core developers would have fixed it. If there was a fork, the social consensus at that point about which is the right chain would start getting discussed and the chain creating unexpected inflation would have likely lost out.”</em> </p><p>In other words, another rollback.</p><figure class="kg-card kg-image-card kg-card-hascaption"><img src="https://lh3.googleusercontent.com/6DMZrkRD97Hs2d23NhXFU_HEeabJHeoX6u8iYWf5rSAv1wAlYuEUcRjg9x205bdDXqPywciQm6o_sRhIGB-whb5YhRjVvWhOdu-hw4g78LLvCDvpo9Xtf87jXsZ0if7osMabEhFe" class="kg-image" alt="How to Hack Bitcoin: A History of Bitcoin Hacks"><figcaption><em>Bitcoin Fell from Its ATH of Nearly $20k in 2017 Down to $3.7k by the End of 2018</em></figcaption></figure><h2 id="how-to-secure-bitcoin">How to Secure Bitcoin?</h2><p>As demonstrated throughout Bitcoin’s history, mining pools have the incentive to act in the best interest of Bitcoin. Though it seems 51% attacks are less likely to happen as a result, <strong>bugs in the Bitcoin codebase remain as prime targets for exploitation</strong>. Increasing the amount of review and testing that code changes receive can help secure Bitcoin.</p><p>If you or your organization are invested in the future of Bitcoin, consider hiring or sponsoring developers who actively review and write tests for the Bitcoin codebase, and please do not rush development. You might find the following resources helpful:</p><ul><li><a href="https://brink.dev/">https://brink.dev/</a></li><li><a href="https://bitcoincore.reviews/">https://bitcoincore.reviews/</a></li><li><a href="https://lists.linuxfoundation.org/mailman/listinfo/bitcoin-dev">https://lists.linuxfoundation.org/mailman/listinfo/bitcoin-dev</a></li><li><a href="https://bitcoinops.org/">https://bitcoinops.org/</a></li></ul><p>If you are looking to secure your own bitcoin holdings, there are many tutorials online. You may want to look up keywords like “cold storage,” “hardware wallets,” “backup seed phrase,” etc.</p><h2 id="is-bitcoin-secure">Is Bitcoin Secure?</h2><p>For a 12 year old piece of software with virtually no loss of funds, nearly 100% uptime, and a $350 billion bounty on its head (ie. the market cap as of 2020-12-05), Bitcoin is still regarded as one of the most secure networks ever created. Though bugs in Bitcoin’s codebase have been exploited in the past; though wallet users have been scammed out of their bitcoins by malicious actors; etc. - <strong>social consensus amongst node operators, miners, developers, businesses, and other participants ensures Bitcoin’s security and value.</strong></p><h2 id="can-bitcoin-be-shut-down">Can Bitcoin Be Shut Down?</h2><p>Though Bitcoin hasn’t worked as expected in the past (see: CVE-2010-5139 and CVE-2013-3220), Bitcoin is one of the most resilient and censorship-resistant networks that has ever existed. As a peer-to-peer network, it has never been shut down and likely never will be, as long as one computer is running Bitcoin software. However, services like merchants and exchanges can be shut down according to local law.</p><hr><p>Hope you found this blog post insightful - if you did, make sure to subscribe to the newsletter to stay up to date on the latest posts!</p><!--kg-card-begin: html--><iframe src="https://bitcoinbriefly.substack.com/embed" width="480" height="320" style="border:1px solid #EEE; background:white;" frameborder="0" scrolling="no"></iframe><!--kg-card-end: html--><p></p><p>What else would you like to learn more about? Let me know on <a href="https://t.me/itsminawhile">Telegram</a>!</p>]]></content:encoded></item></channel></rss>