Pricing overview
The Graph provides two distinct environments for indexing and querying blockchain data, each with its own pricing structure: the Hosted Service and the Decentralized Network (Graph Network). The choice between these services impacts the cost model, payment currency, and operational considerations for developers and data consumers.
The Hosted Service is designed for ease of use and rapid deployment, offering a traditional pay-as-you-go model. Costs are primarily determined by the volume of queries executed against subgraphs. This service includes a free tier, making it accessible for development, testing, and smaller-scale applications. Billing for the Hosted Service typically occurs in fiat currency, such as USD, based on metered usage beyond the free allowance.
In contrast, the Decentralized Network operates as a blockchain-native marketplace where participants interact using the Graph Token (GRT). Data consumers pay query fees in GRT to Indexers who process queries and serve subgraph data. This model involves a more complex economic system, including staking, delegation, and dispute resolution, all denominated in GRT. The cost of queries on the Decentralized Network is dynamic, influenced by supply and demand within the network, and the prevailing market price of GRT.
Both services leverage GraphQL as the query language, allowing developers to define precisely what data they need from various blockchains. This granular control over data requests can influence overall query volume and, consequently, the cost for both pricing models.
Plans and tiers
The Graph's pricing is structured around its two core offerings: the Hosted Service and the Decentralized Network. While the Hosted Service offers defined tiers based on query volume, the Decentralized Network operates on a dynamic, marketplace-driven model.
Hosted Service Tiers:
The Hosted Service provides a straightforward, usage-based pricing model beyond its free tier. There are no fixed subscription plans; instead, users pay for the queries consumed. This model is designed to scale with application usage, from development to production. The primary metric for billing is the number of queries executed against subgraphs. Additional costs are not typically incurred for data transfer or storage within the Hosted Service, as these are factored into the per-query price.
Decentralized Network (Graph Network) Model:
The Decentralized Network does not have traditional tiered plans. Instead, it functions as an open marketplace. Data consumers pay query fees in GRT directly to Indexers for serving subgraph data. The cost per query on the Decentralized Network is not fixed; it can vary based on several factors:
- Indexer Competition: Indexers set their own prices for queries. Competition among Indexers can lead to varying rates for the same subgraph data.
- Subgraph Demand: Highly demanded subgraphs may command higher query fees if Indexers perceive a greater value in serving that data.
- GRT Market Price: Since query fees are paid in GRT, the fiat equivalent cost of a query fluctuates with the market price of the Graph Token (GRT).
- Query Complexity: More complex queries that require greater computational resources from Indexers may result in higher fees.
Users interact with the Decentralized Network by depositing GRT into a gateway, which then routes queries to Indexers and facilitates payment. This model requires users to acquire and manage GRT tokens.
Here's a comparison table outlining the key aspects of each service's pricing approach:
| Feature | Hosted Service | Decentralized Network |
|---|---|---|
| Pricing Model | Pay-as-you-go, query-based | Marketplace-driven, GRT token-based |
| Free Tier | 100,000 queries/month | None specified (requires GRT for queries) |
| Starting Paid Tier | $0.000001 per query (after free tier) | Dynamic, set by Indexers in GRT |
| Payment Currency | USD (or other fiat) | Graph Token (GRT) |
| Billing Frequency | Monthly | Per query (via GRT deposit) |
| Best For | Development, rapid prototyping, smaller dApps, managed infrastructure | Decentralized applications, censorship resistance, long-term sustainability on the Graph Network |
| Key Limits | Query volume, rate limits (documented per API key) | Availability of Indexers, GRT balance, network congestion |
Free tier and limits
The Graph's Hosted Service provides a free tier designed to facilitate development, testing, and the operation of smaller applications without immediate cost. This free tier offers a significant allowance before any charges are incurred.
The free tier for The Graph's Hosted Service includes 100,000 queries per month. This volume is generally sufficient for individual developers, small projects, or the initial stages of dApp development where query loads are moderate. The free tier applies per account, meaning each user or organization can utilize this allowance for their subgraphs deployed on the Hosted Service.
Key aspects and limitations of the free tier include:
- Query Volume: The primary limit is the 100,000 queries per month. Once this threshold is exceeded within a billing cycle, subsequent queries are billed at the standard rate of $0.000001 per query.
- Subgraph Deployment: Users can deploy multiple subgraphs within the free tier, provided the cumulative query volume across all subgraphs remains within the monthly limit.
- Rate Limits: While specific rate limits (queries per second) are not explicitly part of the free tier definition, general API rate limits may apply to ensure service stability. These limits are typically higher than what a free tier user would encounter under normal usage.
- Supported Chains: The free tier supports subgraphs deployed on various chains available on the Hosted Service, such as Ethereum mainnet, Polygon, Arbitrum One, and Optimism, among others. The availability of chains on the Hosted Service is subject to change.
- No Decentralized Network Free Tier: It is important to note that the free tier exclusively applies to the Hosted Service. The Decentralized Network does not offer a free tier in the same manner; all interactions and queries on the Decentralized Network require the use of GRT tokens for payment to Indexers.
For applications that anticipate exceeding the 100,000 query limit, or those requiring the decentralized guarantees of the Graph Network, a transition to paid Hosted Service usage or migration to the Decentralized Network would be necessary.
Real-world cost examples
Understanding The Graph's pricing involves considering both the Hosted Service's query-based billing and the Decentralized Network's GRT-denominated marketplace. Here are some hypothetical scenarios to illustrate potential costs.
Scenario 1: Small dApp on Hosted Service (Free Tier Usage)
- Application: A personal portfolio tracker dApp that fetches token balances and transaction history for a few users.
- Query Volume: The dApp makes an average of 1,000 queries per day, totaling approximately 30,000 queries per month.
- Cost: Since the Hosted Service offers 100,000 free queries per month, this dApp would incur $0.00 in monthly costs. It operates entirely within the free tier limits.
Scenario 2: Growing dApp on Hosted Service (Exceeding Free Tier)
- Application: A popular NFT marketplace dApp that serves metadata, ownership details, and listing information for thousands of users.
- Query Volume: The dApp generates 5 million queries per month.
- Calculation:
- Free queries: 100,000
- Paid queries: 5,000,000 - 100,000 = 4,900,000 queries
- Cost per query: $0.000001
- Monthly cost: 4,900,000 * $0.000001 = $4.90
- Cost: The monthly cost for this dApp on the Hosted Service would be approximately $4.90.
Scenario 3: Enterprise dApp on Hosted Service (High Volume)
- Application: A large-scale DeFi analytics platform requiring extensive historical data and real-time updates across multiple subgraphs.
- Query Volume: The platform executes 500 million queries per month.
- Calculation:
- Free queries: 100,000
- Paid queries: 500,000,000 - 100,000 = 499,900,000 queries
- Cost per query: $0.000001
- Monthly cost: 499,900,000 * $0.000001 = $499.90
- Cost: The monthly cost for this high-volume platform on the Hosted Service would be approximately $499.90.
Scenario 4: dApp on Decentralized Network (GRT-based Costs)
- Application: A dApp prioritizing decentralization and censorship resistance, querying a subgraph on the Graph Network.
- Query Volume: The dApp makes 1 million queries per month.
- Cost: The cost in GRT would depend on the dynamic market price set by Indexers for that specific subgraph. If the average query fee is, for example, 0.0001 GRT per query, and the GRT price is $0.10:
- Total GRT needed: 1,000,000 queries * 0.0001 GRT/query = 100 GRT
- Fiat equivalent cost: 100 GRT * $0.10/GRT = $10.00
- Considerations: Costs fluctuate with both the GRT market price and the Indexer-set query fees. Users must acquire GRT to pay for queries.
These examples highlight that the Hosted Service offers predictable, low costs for a wide range of applications, especially those with high query volumes. The Decentralized Network introduces variability due to the GRT token's market price and the decentralized marketplace dynamics.
How the pricing compares
When evaluating The Graph's pricing, it is useful to compare it with alternative blockchain data indexing and querying solutions. The primary alternatives often fall into two categories: centralized API providers and self-hosted node infrastructure.
Centralized API Providers (e.g., QuickNode, Alchemy, Infura):
Many centralized providers offer RPC (Remote Procedure Call) endpoints and enhanced APIs for interacting with various blockchains. Their pricing models typically involve:
- Subscription Tiers: Often structured with tiered plans that include a certain number of API requests or compute units per month, with overage charges. For example, QuickNode's pricing includes different tiers for API requests and advanced features.
- Request-Based Billing: Similar to The Graph's Hosted Service, but often with more granular distinctions between simple RPC calls and more complex API requests.
- Feature-Based Pricing: Premium features like archival data access, enhanced APIs, or dedicated nodes might be restricted to higher-tier plans or incur additional costs.
Comparison with The Graph's Hosted Service:
- The Graph's Hosted Service offers a highly competitive per-query rate of $0.000001 after its free tier. This can be significantly lower than some centralized providers' per-request costs, especially for standard GraphQL queries against indexed data.
- The free tier of 100,000 queries per month is generous for development and small projects, comparable to or exceeding the free allowances of many centralized services for basic RPC access.
- The Graph's focus on GraphQL for indexed data provides a different value proposition than raw RPC access. While centralized providers might offer some indexed data, The Graph specializes in user-defined subgraphs.
Self-Hosted Node Infrastructure:
For large enterprises or projects with specific privacy and control requirements, self-hosting a blockchain node (e.g., an Ethereum node) and running a custom indexing solution is an option. This involves:
- Infrastructure Costs: Significant expenses for cloud servers, storage, bandwidth, and maintenance. Running a full Ethereum node, for instance, requires substantial disk space and computational resources, as detailed in node setup guides.
- Operational Overhead: Requires dedicated engineering resources for setup, monitoring, scaling, and maintenance.
- Development Time: Building and maintaining a custom indexing solution from scratch is resource-intensive.
Comparison with The Graph:
- The Graph, both Hosted and Decentralized, significantly reduces the operational overhead and infrastructure costs associated with self-hosting. Users can leverage pre-built subgraphs or deploy their own without managing underlying blockchain nodes.
- While the Decentralized Network introduces GRT token management, it still abstracts away the complexities of node operation and data synchronization that come with self-hosting.
The Graph's Decentralized Network vs. Centralized Alternatives:
- The Decentralized Network's GRT-based pricing introduces a different economic model, tied to the value of the GRT token and network dynamics. This contrasts with the fiat-based, predictable costs of centralized providers.
- The core value proposition of the Decentralized Network is censorship resistance and decentralization, which centralized providers by definition cannot offer. The cost reflects this underlying architectural choice.
In summary, The Graph's Hosted Service offers a highly cost-effective and predictable solution for querying indexed blockchain data, especially for projects that can benefit from its generous free tier and low per-query rates. The Decentralized Network provides a unique, token-based pricing model aligned with its goal of a fully decentralized data layer, appealing to projects prioritizing network resilience and censorship resistance over fiat cost predictability.