After months in the making, the implementation of FLIP-660: Variable Transaction Fees has been merged and is being prepared to go into the upcoming spork on April 6, 2022. Variable Transaction Fees allows for transactions submitted to Flow to have pricing which is based upon the total execution effort of the transaction, instead of the simple constant 0.00001 FLOW cost of transactions up to this point.
Why do we want Variable Transaction Fees?
As Flow moves forward on the path to stable cadence and permissionless smart contract deployment there must be some way to account for different usage patterns of this shared resource. For Flow there has long been a split in pricing for storage fees and transaction fees. FLIP-660 improves upon this split by also allowing the network to collect transactions based upon:
- The total execution effort of a transaction
- The cost to the network of including a transaction
- A surge factor
By adding in this granularity, the Flow network is better able to account for the impact to all users and network operators for the execution of transactions. By doing so the overall security of the network is improved, because more expensive operations can bear a higher cost (ultimately reducing spam and non-useful transactions) while keeping basic and common operations priced cheaply.
Call to Action
Dapps, Tools, and Wallets that interact with the Flow Blockchain must review their usage of
gasLimit in transactions as well as if and how they display the total transaction fee to their users before the new variable transaction fees are enabled on mainnet in Late May.
- 31-March 2022: Community review and feedback on FLIP-753 for dynamic transaction fee amounts.
- 06-April 2022: The dynamic transaction fee capability (FLIP-660) is released to testnet and mainnet, but not enabled. Dapps should begin assessing and implementing changes to present and handle dynamic transaction fee amounts.
- 08-April 2022: The dynamic transaction fee is enabled on testnet.
- 08-April to 22-April 2022: The community will vote on dynamic transaction fee amounts to be applied.
- Late May: Pending vote results, the dynamic transaction fee is enabled on mainnet (FLIP-753). Dapps should be ready to present and handle dynamic transaction fee amounts by this time. Read the FAQ below for more info.
When will this change go into effect?
Fee changes will not immediately occur after the April 6th spork. A community vote will take place shortly after the code is live to approve the specific fee structure to be used as a starting point. Details of this vote will be available after FLIP-753 has been merged.
What will transactions cost after the change is applied?
Dapps and Wallets must be able to support transactions with a cost greater than 0.001 FLOW. While the goal of FLIP-753 will be to price the average transaction below the existing cost, it does mean that some transactions can go above the fixed 0.0001 FLOW today. Any application or wallet which displays transaction prices in Flow should be aware of this and calculate the actual price based upon the final values in FLIP-753.
How do I determine the execution effort (gas) limit for my transactions?
Since there is no current API for estimating the effort of a transaction, it is recommended that developers utilize the Flow Simulator and Testnet to profile transactions and determine their range of execution effort.
For transactions which can use an arbitrary amount of execution effort, it is recommended that transactions are passed the maximum value of
Will there be any changes to FCL or other SDKs?
The FCL currently allows Dapps to set the gas limit for a transaction but defaults to a low value if none is passed. This functionality remains the same after this change.
The Flow Golang SDK currently defaults to
9999 if no gasLimit is set and
NewTransaction() is used, otherwise it defaults to
It is notable that Dapps should re-evaluate whether their current fixed gasLimits will work under the new transaction fee proposal.
When will I be able to test transactions?
The fee amounts being proposed in the FLIP-753 community vote will be applied to testnet when it is upgraded after the April 6th spork has completed successfully. At that time you will be able to test transactions by observing the
FlowFees.FeesDeducted event which will change after the spork to reflect the new execution effort of a transaction.
Work is currently in progress on providing support for the new fee structure in the Flow Emulator.