DeFi

March 12, 2024

Polygon zkEVM: New Custom Endpoints for dApps

Recent changes to the network caused users to see estimated gas prices that were much higher than the transaction fee paid. This custom endpoint is the solution.

DeFi

Earlier this year, Polygon zkEVM changed how it calculated transaction fees. While the actual transaction fee paid by users went down for most types of DeFi activity, there was one unintended consequence: The estimated gas price users had to sign was much higher than what they would end up paying. 

If you have a dApp deployed on Polygon zkEVM, this solution is for you. Using this custom endpoint is not obligatory, but strongly recommended.

Relevant Calls 

Standard endpoint

  • eth_estimateGas returns the gas needed to execute the transaction, given the state of the network

New custom endpoints 

  • zkevm_estimateGasPrice returns an almost exact gas price based on the transaction type and calldata being used, given the state of the network.
  • zkevm_estimateFee returns the estimated transaction fee following the estimated gas price, given the state of the network.

How-to for dApps devs

The relevant JSON content and documentation can be found here: 

  1. Copy the JSON content for node v0.5.13: zkevm-node / json / 0.5.13
  2. You can visualize the spec by pasting the code into the playground area of the OpenRPC Playground
  3. The process is the same as requesting eth_estimateGas. You’ll call the new endpoints with the exact same parameters. For additional reference, see the call examples below.
eth_estimateGas
zkevm_estimateGasPrice
zkevm_estimateFee

Given the state of the network and the responses to the above calls, the new custom endpoint returned an estimated fee that was ~20% lower than the standard endpoint. Note: On dApps that continue using the standard endpoint, users are always going to sign the higher price but the actual fee paid will be the same as with the custom endpoint. 

For RPC infra providers: node compatibility

This custom endpoint is available for Node version 0.5.13, which was included in the Etrog upgrade: 

If you’re an infrastructure provider running RPC nodes on Polygon zkEVM, you need to update to the latest release of the node on mainnet for dApps to call zkevm_estimateGasPrice.

Nearly all of the node providers on Polygon zkEVM are already running the latest version. 

Additional Material

A complete list of all JSON RPC endpoints supported on Polygon zkEVM can be found here: 

Tune into the blog and our social channels to keep up with updates about the Polygon ecosystem.

The future of blockchains is aggregated.

Website | Twitter | Forum | Telegram | Discord | Instagram | LinkedIn | Polygon Knowledge Layer

Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

June 26, 2026

Payments
Polygon Chain

We Built the Best Blockchain for Payments. Now We’re Bringing the World’s Enterprises Onchain

June 22, 2026

Institutional
Open Money Stack
Payments

Uquid Integrates Polygon's Open Money Stack for 1-Click Crypto Checkout Across 178M+ Products

June 19, 2026

Open Money Stack
Polygon Chain
Payments

How to Integrate Stablecoins into Your Payment Product

June 17, 2026

Polygon Chain
Open Money Stack
Institutional

Polygon Chain Now Supports 5000 Payments per Second, Hitting the Speed of a Card Network at a Fraction of the Cost

June 12, 2026

Institutional
Polygon CDK

Three Things We Learned About What Banks Need to Build Successful Blockchains

June 11, 2026

Polygon Chain
Payments

A Billion Fans, Five Weeks, One Network: We Spent Six Months Preparing Polygon Chain for the Summer's Biggest Sporting Event

June 10, 2026

Institutional
Payments
Open Money Stack

Mastercard Launches Agent Pay for Machines. Polygon Is Part of the Ecosystem Supporting It

June 8, 2026

Wallets
Open Money Stack
Payments

Run Recurring Subscriptions, Payouts, and Checkouts on a Non-custodial Wallet with One Customer Approval via the OMS

June 4, 2026

Open Money Stack
Payments

Polygon Open Money Stack Enters Technical Preview

June 3, 2026

Institutional
Polygon Chain

Mastercard Expands Settlement to Nights, Weekends, Holidays on Polygon

Next
PREV
More Blogs