As per Ethereum's EIP-1559 explanation

It is possible that miners will mine empty blocks until such time as the base fee is very low and then proceed to mine half full blocks and revert to sorting transactions by the priority fee


Static 'Priority Fee' Vs 'Dynamic Priority Fee' ?

  • If miners sort transactions based on priority fee or Tip to be get included in the next block, Is it possible that static priority fee results into pending transactions if the base fee remains same for the past or future set of blocks?

  • How to pro-grammatically calculate priority fee or Tip to avoid pending transactions in future?


1 Answer 1


Answering your second question to calculate maxFeePerGas programmatically you could call this function in ethers.js provider.getFeeData() which will return maxFeePerGas maxPriorityFeePerGas gasPrice, however currently it seems maxPriorityFeePerGas is hardcoded to a value of 2.5 gwei as per their code.

Alchemy has the function eth_maxpriorityfeepergas to fetch it dynamically, which seems working well for me (even for the polygon network). Link to their docs.

  • Why would they hard-code 2.5 gwei :( Commented Jun 28, 2023 at 8:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.