2 minutes
About The Graph
Explanation
What is The Graph?
The Graph is a decentralized protocol for indexing and querying blockchain data. Its suite includes Subgraphs, Substreams, Token API BETA, and tools like Graph Explorer and Subgraph Studio.
The Graph supports 90+ blockchains, enhancing dapp development and data retrieval.
Why is Blockchain Data Hard to Query?
Reading onchain data from the blockchain (e.g., ownership history, metadata, relationships between assets) typically requires processing smart contract events, parsing metadata from IPFS, and aggregating data manually. This is very slow, complex, and resource-intensive.
Solution
How The Graph Solves This
The Graph simplifies the complex process of retrieving blockchain data through a global, decentralized network of Indexers that index Subgraphs. This infrastructure facilitates efficient, censorship-resistant query handling, allowing developers to build applications using blockchain data without the hassle of managing servers or custom indexing.
Each Subgraph defines:
- Which smart contracts to watch
- Which events to extract
- How to map event data into a queryable format using GraphQL
Building a Subgraph
- Define a Subgraph Manifest with data sources and mappings.
- Use Graph CLI to deploy the manifest to IPFS.
- An Indexer picks it up and starts indexing Ethereum blocks.
- Data becomes queryable via a GraphQL endpoint.
Data Flow Overview
-
A dapp triggers a transaction on Ethereum by interacting with a smart contract.
-
As the transaction is processed, the smart contract emits one or more events.
-
Graph Node continuously scans the Ethereum blockchain for new blocks and filters for events relevant to a deployed Subgraph.
-
When a matching event is identified, Graph Node executes the Subgraph’s mapping logic, which is a WASM module that transforms event data into structured entities. These entities are subsequently stored and indexed.
-
The dapp queries the Graph Node via a GraphQL API, retrieving indexed data to render in the UI. Users can then take actions that generate new transactions, continuing the cycle.
The diagram below provides more detailed information about the flow of data after a Subgraph manifest has been deployed with Ethereum transactions.

Next Steps
Explore Graph Explorer to view and query existing Subgraphs.