Archive data is data on the blockchain that is older than 128 blocks. Archive data is at least 25.6 minutes old because one block can be created every 12 seconds. Archive data is also at least 4 epochs old (128 slots) because there are 32 slots per epoch, and 1 block can be validated in each slot. Because archive data is at least 4 epochs old, the commitment level for archive data is considered "finalized". This data is used to store information about past transactions and events that have occurred on the blockchain network. This data is used by users to help them understand the history of the network and to make sure that all transactions and events that have occurred on the network are valid.
Full nodes store the current and most recent blockchain states (up to the last 128 blocks) and participate in validating newly added blocks. They can process transactions, execute smart contracts, and query/serve blockchain data. They can also access some historical data (via tracing) but are inefficient for this task.
Archive nodes store the same information as full nodes and all previous states of the blockchain(data older than 128 blocks). Running an archive node requires the most investment in hardware, running costs, technical expertise, and experience. Archive nodes build archival blockchain data quickly and efficiently, and they’re useful for querying arbitrary historical data, like a user’s balances on a specific block.
Only an archive node can serve API requests for certain RPC methods older than 128 blocks. The Ethereum JSON-RPC and Websocket APIs include several methods which require access to an archive node.
Requests for data older than the most recent 128 blocks require access to archive data. The following methods include a parameter for specifying a block number for the request:
These methods can also be used to get non-archive data. Archive data access is required only if you request data older than 128 blocks using these methods.
Here are two use-cases for Ethereum archive data:
If you're building a service to audit a blockchain or gather specific pieces of historic data, archive data is ideal. A good use-case would be if you were building a blockchain explorer (Etherscan), an on-chain analytics tool (Dune Analytics), or a cryptocurrency wallet.
These services rely on archive nodes to query and serve up old state data for users. For example, you can get information about the first block mined on Ethereum using Etherscan.
dApps that need to access data older than 128 blocks require access to archive data.
Examples of dApps that may need access to an archive data include:
On-chain reputation services (e.g. DegenScore) that track user activity over a large period of time.
Governance platforms (e.g., Tally, Snapshot) that allow users to discuss and vote on governance proposals.
Alchemy's Supernode supports unlimited requests for archive data and provides access to all the historical blockchain information you need. The good part? You can connect to an archive node for free.
Even though archive data is more expensive to get, Alchemy offers unrestricted archive node access even for users on Supernode’s free tier. This means you can get past on-chain data and even fork the entire chain from genesis, without paying additional fees.
Here is a step-by-step process for requesting archive data with Alchemy:
Sign up for an account (it's free!) and create your first project.
Create your Alchemy key. This is the URL endpoint for getting realtime and archive data.
Start sending requests to this endpoint for archive data.
Archive nodes can store past blockchain states extending beyond the most recent 128 blocks. If your dApp or Web3 service requires accessing historical blockchain data(data older than 128 blocks), running an archive node is a no-brainer. But be aware that the demands of running a fully functional archive node can discourage developers and stall development plans.
Alchemy’s Supernode solves this problem by connecting users with archive nodes that use free URL endpoints. With Alchemy, getting archive data has never been easier!
Updated about 2 months ago