General Settings
Unique identifier for this Graph Node instanceRequired when running multiple nodes in parallel. Each node must have a unique ID. The same node should use the same ID across restarts.
Use literal
node_id value in Docker without replacing hyphens with underscoresDocker only. Changing this for an existing installation requires updating node_id values in subgraphs.subgraph_deployment_assignment table.Graph Node logging configurationUses same syntax as Rust’s env_logger.Levels:
error, warn, info, debug, traceEnable detailed query timing logsComma-separated list:
sql, gql, cachegql: Log GraphQL queries with timing, subgraph, variables, and unique query_idsql: Log SQL queries with timing, bind variables, and entity countscache: Log cache hits/misses for GraphQL queries
Log Proof of Indexing events deterministicallyUseful for debugging POI-related issues.
Kill the process if it becomes unresponsiveSet to any value to enable.
Timeout in seconds before killing unresponsive nodeOnly used if
GRAPH_KILL_IF_UNRESPONSIVE is set.Ethereum / EVM Chain Configuration
Maximum expected reorg size in blocksIf a larger reorg occurs, subgraphs may process inconsistent data.
How often to poll Ethereum for new blocks (milliseconds)
Target number of triggers to process per batchToo small: Excessive requests to Ethereum node
Too large: Expensive calls and high memory usage
Number of blocks to scan per RPC request when fetching tracesUsed for call handlers and block handlers with call filters.
Number of Ethereum blocks to request in parallelAlso limits parallel requests like
trace_filter.Maximum block range to scan for triggers in each request
Maximum range for
eth_getLogs requests filtering only by event signature (not contract address)Timeout for Ethereum JSON-RPC requests
Number of retries for Ethereum JSON-RPC requestsFor requests that won’t fail the subgraph but will restart syncing (e.g., requesting a reorged block).
Maximum concurrent requests for transaction receipts during block ingestion
Fetch transaction receipts in batches instead of concurrentlyAutomatically set to
true on macOS to avoid DNS issues.Clean up unneeded blocks from the cacheDevelopment only. In production, causes multiple downloads of the same blocks. Cannot be used with multiple shards.
Specify genesis block number
Maximum number of contracts to query in a single
eth_getLogs requestTimeout (seconds) for checking
eth_getBlockReceipts supportIf timeout occurs, individual transaction receipts are fetched instead.Disable block ingestionSet to
true to disable, false or unset to enable.Firehose Configuration
Maximum size of a message that can be decoded by Firehose
Mapping Handlers
Maximum execution time for a mapping handler (seconds)Default: unlimited
Entity cache size in kilobytesDefault is 10MB.
Maximum supported
apiVersion in subgraph manifestsSubgraphs with higher versions will be rejected.Maximum supported
specVersion in subgraph manifestsSubgraphs with higher versions will be rejected.Maximum WASM runtime stack sizeExecution stops with an error if exceeded.
IPFS Configuration
Timeout for IPFS requests (seconds)Includes manifest files and
ipfs.cat calls from mappings.Maximum file size for
ipfs.cat calls (bytes)Default: 25 MiBAffects both subgraph files and file data sources.Maximum file size for
ipfs.map (bytes)Default: 256 MBEntities from ipfs.map are kept in memory during processing.Maximum number of files to cache from IPFS
Maximum size of each cached IPFS file (bytes)Default: 1 MiB
Rate limit for IPFS file data source requests (per second)
Maximum retry attempts for IPFS requestsPrevents infinite retries on file not found or other errors.
File or Redis cache location for IPFS filesExperimental. Can be:
redis://host:port- Redis cache/path/to/directory- Filesystem cache (must be writable)
Enable
ipfs.cat in subgraph mappingsExperimental and non-deterministic. Will be removed in future versions.GraphQL Configuration
Maximum GraphQL query execution time (seconds)Default: unlimited
Maximum GraphQL query complexityDefault: unlimitedIntrospection queries have complexity ~1 million. Set higher than that to allow introspection.
Maximum GraphQL query depthMaximum allowed: 255
Maximum value for
first argument in queriesMaximum value for
skip argument in queriesDefault: unlimitedLog warning if GraphQL result exceeds this size (bytes)Default: unlimited
Return error if GraphQL result exceeds this size (bytes)Default: unlimitedChecked during response construction to prevent excessive memory use.
Port for GraphQL HTTP server
Maximum SQL query execution time during GraphQL execution (seconds)Default: unlimited
Enable GraphQL specification validationsValidates queries follow GraphQL execution rules.
Only log GraphQL validation errors without failing queriesOnly used if
ENABLE_GRAPHQL_VALIDATIONS=true.Queries may still fail during execution stage.Disable AND/OR filters for performanceUseful if complex filters cause performance issues.
Disable child-based sorting for performanceUseful if child sorting causes performance issues.
Token to enable query tracingRequests with Then in requests:
X-GraphTraceQuery header matching this token will include SQL query traces.GraphQL Query Caching
Subgraphs to cache queries for
*: Cache all subgraphs (default)- Comma-separated list: Cache specific subgraphs
Number of recent blocks per network to keep in query cacheSet to
0 to disable caching. Keep small as lookup time and memory are proportional to this value.Maximum memory for query cache (MB)Default: 1 GBTotal cache memory is 2x this value (recent blocks + frequent queries).
Number of queries after which a cache entry can be considered stale
Maximum cache entry size ratioResults larger than (cache shard size / ratio) won’t be cached.Set to
0 for no limit.Database Configuration
Database connection pool sizeMay not be strictly adhered to due to implementation details.
Database connection timeout (milliseconds)If exceeded, database is assumed down.
Database setup operation timeout (milliseconds)Default: 30 secondsUsed for migrations and schema creation, which may take longer than normal operations.
Probe interval when database shard is unavailable (seconds)Only one request per interval attempts connection; others fail instantly.
PostgreSQL URL for running testsFormat:
postgresql://user:password@host:port/databaseTarget duration for batch operations during copying/grafting (seconds)Controls transaction length for long-running operations.
Maximum batch operation timeout (seconds)Default: unlimitedShould be a small multiple (e.g., 10x) of
GRAPH_STORE_BATCH_TARGET_DURATION.If hit, batch size resets to 1 and retries.Number of parallel workers for batch operationsMinimum: 1Uses idle connections to copy tables in parallel during subgraph copy operations.
How long to accumulate changes before writing (seconds)Set to
0 to disable write batching.How many changes to accumulate before writing (kilobytes)Default: 10 MBSet to
0 to disable write batching.Disable storing/reading
eth_call results from cacheUseful for indexers running their own RPC nodes. May significantly impact performance depending on eth_call execution time vs database lookup cost.Postpone creating attribute-based indexes during subgraph copyCan speed up syncing.
Workaround for ‘too many parameters’ PostgreSQL errorsIf encountering “number of parameters must be between 0 and 65535” errors, set to ~10.Such errors are always Graph Node bugs; this provides a temporary workaround.
Database Pruning and History
History accumulation threshold before pruningMinimum: 1.01At 1.2, subgraph is pruned when it contains 20% more history than its limit.
Prune by copying entities to new tables if removing more than this fractionMust be between 0 and 1, and greater than
DELETE_THRESHOLD.Prune by deleting from existing tables if removing between this and REBUILD_THRESHOLDMust be between 0 and 1, and less than
REBUILD_THRESHOLD.If removing less than this threshold, no pruning occurs.Minimum blocks to retain for subgraphs with
historyBlocks: autoDefault: 2 × reorg thresholdHow long to wait before removing unused deployments (minutes)Default: 6 hoursGraph Node periodically marks unused deployments, then waits this interval before deletion.
Experimental Database Features
Enable experimental SQL query interface
Interval for account-like optimization scan (hours)Requires also setting:
GRAPH_STORE_ACCOUNT_LIKE_MIN_VERSIONS_COUNTGRAPH_STORE_ACCOUNT_LIKE_MAX_UNIQUE_RATIO
info.table_stats materialized view (refreshes every 6 hours).Minimum total versions for account-like flaggingRequired for account-like optimization scan.
Maximum unique entities to version ratioExample: 0.01 ≈ 1:100 entity-to-version ratioRequired for account-like optimization scan.
Load Management
Load measurement window size (seconds)Used with
GRAPH_LOAD_BIN_SIZE for load throttling.Load measurement bin size (seconds)Measurements within window are binned into intervals of this size.
Database connection wait time threshold for throttling (milliseconds)Default: 0 (throttling disabled)If connection wait times exceed this, queries are throttled until wait times drop below threshold.
Effort fraction threshold for permanently rejecting queriesWhen overloaded, queries causing more than this fraction of effort are permanently rejected (even after overload resolves).If unset, no queries are jailed (but still subject to throttling).
Simulate load management without declining queriesPerforms all load management steps but only logs decisions instead of rejecting queries.
Subgraph Features
Subgraph version switching behavior
instant: Switch immediately when new version deployedsynced: Only switch after new deployment syncs (becomes “Pending” version)
Starting block for forked subgraphFormat:
block_hash:block_numberAPI URL for subgraph forking
IPFS hash of subgraph to fork
Example Configurations
Development Environment
Production Environment
Query Node
Index Node
Next Steps
- Docker Setup - Run Graph Node with Docker
- Configuration Overview - Advanced TOML configuration
- Building from Source - Compile Graph Node

