Post
Topic
Board Bitcoin Discussion
Re: Algorithm for selecting a low-fee transaction from the mempool
by
bomberb17
on 19/05/2023, 13:55:50 UTC
My question is what is the algorithm that a miner picks a transaction from the mempool to include it to a block?
Miners prioritize transactions based on their fee rate. The more fee rate you use for your transaction, the faster it can be included in the blockchain.


Is it a greedy algorithm which just picks the ones with highest fees? Is the "age" of a transaction in the mempool also a factor? Or is it just a combination of fee and a random choice?
It doesn't matter when you have broadcasted your transaction. It all depends on the fee rate.

So you say it is purely a greedy algorithm?