Graph's Subgraphs and Substreams Differ in Purpose: One for User-Facing Apps, the Other for High-Volume Data
The Graph offers two solutions to help developers navigate the complexities of blockchain data: Subgraphs and Substreams. While both tools have their strengths, they cater to different use cases.
Subgraphs are ideal for user-facing applications that require relational queries. They index on-chain events, structure them, and expose the results through GraphQL, making it easier for frontends to request specific data without crawling the chain itself.
However, Subgraphs have limitations when dealing with high-throughput chains or large datasets. In such cases, Substreams come into play. These tools process history in parallel rather than block by block, allowing for faster and more efficient handling of large amounts of data.




