How Is the Total Transaction Fee Calculated Using Gas and Gas Price?
The total transaction fee is calculated by multiplying the amount of gas consumed by the transaction by the effective gas price paid. Before EIP-1559, this was simply Gas Used Gas Price.
With EIP-1559, the calculation is Gas Used (Base Fee + Priority Fee). The resulting value is the total amount of the native currency (e.g.
ETH) paid for the transaction.