Solana Mainnet
- Type
- mainnet
- Identifier
- solana-mainnet-beta
- Chain ID
- solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp
- Native Currency
- SOL
Indexing Data on Solana
Solana is a high-throughput Layer 1 known for fast, low-cost transactions and a large DeFi, NFT, and payments ecosystem. The Graph can stream that onchain activity — program interactions, DEX swaps, token transfers and balances, and account updates — as real-time data with Substreams.
Solana is supported by The Graph with Substreams — a parallelized, real-time streaming engine for high-throughput use cases — via The Graph Market and Pinax Network.
Indexing Solana with Substreams
Substreams is a parallelized, real-time streaming engine for extracting and transforming blockchain data. Where a Subgraph indexes into a hosted GraphQL API, Substreams lets you consume high-throughput data directly or via 10+ supported sinks. Solana is available through Substreams’ Solana block model, so modules have access to blocks, transactions, and instructions. Modules are written in Rust and composed into reusable packages.
Find an Existing Module on Substreams.dev
Before writing any code, check the Substreams Registry for a package that already does what you need. The registry hosts community- and team-built modules covering common onchain data that you can run as-is or compose into your own pipeline. Search for the protocol or data you want on Solana; if a module fits, you can consume its output directly or import it as a dependency in your own project.
Develop Your Own Substreams Module
If no existing module fits, you can build one. The Substreams Quick Start is the full walkthrough. In short:
- Install the Substreams CLI and get a key at thegraph.market (no personal information required).
- Scaffold a project with
substreams initand choose the Solana path. - Write your extraction and transformation logic in Rust, then run
substreams build. - Stream the output with
substreams gui(orsubstreams run) to iterate, then publish your package to the Substreams Registry to reuse or share it.