<p>As of Bitcoin Core v24.0rc1, and probably since ancestor-aware mining has been included, the txid is used as tie-breaker:</p>
<p><a href="https://github.com/bitcoin/bitcoin/blob/v24.0rc1/src/txmempool.h#L293" rel="nofollow noreferrer">https://github.com/bitcoin/bitcoin/blob/v24.0rc1/src/txmempool.h#L293</a></p>

CC BY-SA 4.0
2022-10-07T19:37:35.633Z
2022-10-07T19:37:35.633Z
Pieter Wuille
<p>Bitcoin Core greedily picks the ancestor sets with the highest ancestor score into its block template. When two transactions have the same ancestor score (e.g. two transactions without unconfirmed ancestors that have the same feerate) during block building, does Bitcoin Core randomly pick one, or does one get preferred per some criteria?</p>

<bitcoin-core-development><transaction-selection>
Which transaction gets picked when ancestor scores tie?
Murch
# Which transaction gets picked when ancestor scores tie?

(Asked by: username_0 on 2022-10-07)

Bitcoin Core greedily picks the ancestor sets with the highest ancestor score into its block template. When two transactions have the same ancestor score (e.g. two transactions without unconfirmed ancestors that have the same feerate) during block building, does Bitcoin Core randomly pick one, or does one get preferred per some criteria?

**Tags:** bitcoin-core-development, transaction-selection


---

## 1 answers

### Answer by username_1 on 2022-10-07. Score: 2 | Accepted answer

As of Bitcoin Core v24.0rc1, and probably since ancestor-aware mining has been included, the txid is used as tie-breaker:

<https://github.com/bitcoin/bitcoin/blob/v24.0rc1/src/txmempool.h#L293>


---

