Skip to main content

What is archive node RPC?

Archive node RPC is JSON-RPC access to nodes that keep every past state of a chain, so you can query what a balance or contract value was at any earlier block, not only what it is now.

Wallets, custody providers, chains and transaction monitoring vendors use it for statements, audits, investigations and backtests, which all need what an account held at a point in time.

Goldsky’s Edge RPC sends requests for history to archive nodes behind one endpoint on EVM chains and fails over between providers, while the calls you make and what you do with the responses stay with you.

Who uses archive node RPC?

Wallets, custody providers, blockchain networks and transaction monitoring vendors that need balances and contract state as they were at a past block.

How an archive node RPC call works

The diagram follows one request from your app requesting an old balance to the statement, audit or backtest that uses the answer, and shows who does each step. Your setup may differ.

Your business, step 1: Need past stateYour app asks for an old balance
Goldsky, step 2: EdgeRoute to an archive nodeOne endpoint sends history to archive nodes
Your business, step 4: Use the answerStatements, audits or backtests get the value
Goldsky, step 3: EdgeRead state at that blockBalances or contract state, as they were
  • Goldsky

How to read historical chain state over archive node RPC

Your code sends standard JSON-RPC calls with a past block number to one Edge RPC endpoint, which routes them to archive nodes and returns the state as it was at that block.

What you’ll need

  • Goldsky Edge
  • The block number, or the date, you need state at
  • Client code that sends JSON-RPC calls and decodes the results
  • Storage for the responses, if you reuse them in statements or audits
  1. Decide what state you need, and at which block

    A statement or an audit asks about one moment, so you need the exact block that matches it.

    Turn the date into a block number on the chain you’re reading, and list the accounts and contract values to read at that block. A block a few seconds off the cutoff can include or miss a transaction that changes the answer.

  2. Send the request to an archive node

    Handled by Goldsky Edge

    Ordinary full nodes drop old state, so a request for history has to reach a node that kept it.

    The request has to land on a node that holds the state for that block, and keep working when one provider is down. Sent to a node that pruned it, the request fails with a missing-state error.

    With Goldsky, Edge RPC routes requests for historical data to archive nodes on its own, fails over between providers during outages and cross-checks responses from several nodes before responding.

    See how Edge RPC routes requests (opens in a new tab)
  3. Read the state at that block

    Handled by Goldsky Edge

    The answer you need is the value as it stood then, such as a balance or a figure a contract stored.

    Calls such as eth_getBalance for a native balance, or eth_call for a token balance or other contract value, take a block number and return the state as of that block. Left as latest, they return today’s value, and the report shows the wrong date without any error.

    Edge RPC accepts the standard methods with a hex block number, so eth_call to a token’s balanceOf at that block returns the holding as it was. Edge RPC serves EVM chains only, and trace methods such as debug_traceTransaction are served from the same endpoint.

    Read the eth_call reference (opens in a new tab)
  4. Use the answer

    Statements, audits and backtests are what the historical read is for.

    Decode the returned hex into amounts with the token’s decimals, and store each value with its block number and hash. Without the block reference, nobody can check later which point in time the figure came from.

What you control

Your team
  • Decide what state you need, and at which block
  • Use the answer

Questions and answers

What’s the difference between a full node and an archive node?

A full node keeps a chain’s current state, while an archive node keeps every past state, so only an archive node can say what a balance was at an old block. Full nodes check every block but prune older state to save storage, so a call such as eth_getBalance at a block from months ago fails on most of them. Archive nodes keep that state, which takes much more storage, and that is why many teams reach archive data through a provider.

Security and deployment

  • SOC 2 Type IIIndependently audited security controls.
  • Dedicated infrastructureSingle-tenant options for production workloads.
  • Data residencyCloud, on-premises or co-located.

Read historical chain state over archive node RPC with Goldsky

We’ll map it to your systems and show you what Goldsky runs, so your team builds the product, not the pipelines underneath it.

© Endless Sky Inc. All rights reserved.

PrivacyTermsSecurity

System status