llms.txt
# Solana Documentation
> Developer documentation for Solana, the high-performance blockchain.
## Instructions
- Every page below is available as raw Markdown by appending `.md` to its
URL (the links here already include it), or by requesting the page URL
with an `Accept: text/markdown` header.
- The full corpus in a single file: https://solana.com/llms-full.txt
- Scoped indexes exist per section, e.g.
https://solana.com/docs/finance/llms.txt,
https://solana.com/docs/payments/llms.txt or
https://solana.com/docs/tokenization/llms.txt - prefer these when
working on a single task to save context.
- If you are a coding agent, install the official Solana skill for
current APIs and conventions: `npx skills add
https://github.com/solana-foundation/solana-dev-skill` (also served at
https://solana.com/SKILL.md).
- Route financial tasks through /docs/finance: asset fundamentals are
under /docs/tokens, payments under /docs/payments, stablecoins and
tokenized assets under /docs/tokenization, and markets and DeFi under
/docs/defi. The JSON-RPC reference is under /docs/rpc; self-contained
code recipes under /developers/cookbook.
- Code in the cookbook and task pages is sourced from tested example
files - prefer it over synthesizing API calls from memory.
## Core documentation
- [Start Here](https://solana.com/docs.md): Choose a quickstart, code with an AI agent, or learn how Solana works.
- [Solana SDKs](https://solana.com/docs/clients.md): SDKs for building on Solana - TypeScript, Rust, Python, Java, Go, and game engines.
- [Solana Gaming SDKs](https://solana.com/docs/clients/community/game-sdks.md): A list of Solana Gaming SDKs to get you started creating your first Solana Game
- [Go SDK](https://solana.com/docs/clients/community/go.md): Learn how to interact with Solana using the Go SDK (gagliardetto/solana-go).
- [Java SDK](https://solana.com/docs/clients/community/java.md): Learn how to interact with Solana using the Java SDK (sava-software/sava).
- [Python SDK](https://solana.com/docs/clients/community/python.md): Learn how to interact with Solana using the Python SDK (michaelhly/solana-py).
- [Typescript SDK](https://solana.com/docs/clients/official/javascript.md): Learn how to interact with Solana using the JavaScript/TypeScript client libraries.
- [Rust SDK](https://solana.com/docs/clients/official/rust.md): Official Rust crates for building on Solana.
- [Core Concepts](https://solana.com/docs/core.md): Solana's core building blocks, including accounts, programs, instructions, transactions, fees, program-derived addresses, and cross-program invocations.
- [Accounts](https://solana.com/docs/core/accounts.md): Solana accounts are the fundamental data unit for storing state on the network. Account structure, addresses, types, rent, ownership, and modification rules.
- [Account Runtime](https://solana.com/docs/core/accounts/account-runtime.md): How the Solana runtime loads and validates accounts before execution, and the serialization format used to pass account data to programs.
- [Account Structure](https://solana.com/docs/core/accounts/account-structure.md): Account addresses, the five fields every Solana account contains — lamports, data, owner, executable, and rent_epoch — with interactive code walkthrough.
- [Account Types](https://solana.com/docs/core/accounts/account-types.md): Solana account types — program accounts for executable code, data accounts for program state, system accounts owned by the System Program, and sysvars for cluster-wide state at predefined addresses.
- [Modification Rules](https://solana.com/docs/core/accounts/modification-rules.md): Runtime-enforced rules for modifying Solana account lamports, data, owner, executable flag, and borrow semantics.
- [Constants Reference](https://solana.com/docs/core/constants-reference.md): Centralized reference for all Solana runtime constants including accounts, transactions, instructions, programs, fees, compute units, PDAs, and CPIs.
- [Cross Program Invocation](https://solana.com/docs/core/cpi.md): Cross Program Invocation (CPI) on Solana — how programs call other programs using invoke and invoke_signed, handle PDA signers, and compose onchain functionality.
- [CPI Cost Model and Data Sync](https://solana.com/docs/core/cpi/cpi-cost-model.md): CPI compute costs, account data synchronization between caller and callee, PDA signing mechanics, and return data on Solana.
- [CPI Execution and Privileges](https://solana.com/docs/core/cpi/cpi-execution.md): The 11-step CPI execution flow through the Solana runtime, privilege extension rules, reentrancy restrictions, and authorized program checks.
- [CPIs with PDA Signers](https://solana.com/docs/core/cpi/cpi-with-pda.md): How to use the invoke_signed function for Cross-Program Invocations on Solana when the calling program needs to sign as a PDA, with Anchor CpiContext and Native Rust examples.
- [CPIs without PDA Signers](https://solana.com/docs/core/cpi/cpi-without-pda.md): How to use the invoke function for Cross-Program Invocations on Solana when no PDA signing is required, with Anchor CpiContext and Native Rust examples.
- [Fees](https://solana.com/docs/core/fees.md): Solana transaction fees consist of a base fee of 5,000 lamports per signature and an optional prioritization fee, priced in micro-lamports per compute unit for legacy and v0 transactions and as an absolute lamport total for v1. Fee calculation, distribution, and compute budget.
- [Compute Budget](https://solana.com/docs/core/fees/compute-budget.md): Compute unit limits, ComputeBudgetInstruction variants, the scheduler cost model, block limits, and execution budget constants on Solana.
- [Fee Structure](https://solana.com/docs/core/fees/fee-structure.md): How Solana transaction fees are calculated, including the base fee per signature, the prioritization fee formula, fee distribution, and how to set fees using compute budget instructions.
- [Instructions](https://solana.com/docs/core/instructions.md): Solana instructions are the smallest unit of program execution. Each instruction targets one program and specifies accounts, data, and signer requirements.
- [Instruction Introspection](https://solana.com/docs/core/instructions/instruction-introspection.md): How Solana programs inspect other instructions in the same transaction using the Instructions sysvar. Load instructions by absolute index or relative offset. CPI inner instructions are not accessible.
- [Instruction Structure](https://solana.com/docs/core/instructions/instruction-structure.md): Solana instruction structure — program_id, accounts, and data fields, AccountMeta flags is_signer and is_writable, compiled instructions, and SOL transfer examples in TypeScript and Rust.
- [Program Derived Addresses (PDAs)](https://solana.com/docs/core/pda.md): Solana Program Derived Addresses (PDAs) are deterministic, off-curve addresses derived from seeds and a program ID. No private key exists — only the deriving program can sign via invoke_signed.
- [PDA Accounts](https://solana.com/docs/core/pda/pda-accounts.md): Create onchain accounts at Solana PDA addresses using invoke_signed and Anchor's init constraint. invoke_signed verification flow and Anchor PDA creation patterns with code examples.
- [PDA Derivation](https://solana.com/docs/core/pda/pda-derivation.md): How Solana PDAs are derived using SHA-256 with seeds, bump values, and a program ID. Derivation algorithm, canonical bump search, compute costs, and SDK examples in TypeScript and Rust.
- [Programs](https://solana.com/docs/core/programs.md): Solana programs are executable code stored onchain. Overview of program types, the sBPF execution model, deployment and upgrades, and the Anchor, Pinocchio, and native Rust development approaches.
- [Core Programs](https://solana.com/docs/core/programs/builtin-programs.md): Solana core programs — System Program with instruction reference, Vote, Stake, Config, Compute Budget, Address Lookup Table, and ZK ElGamal Proof. Includes source links for all 7 programs.
- [Precompiled Programs](https://solana.com/docs/core/programs/precompiles.md): Solana's precompiled programs for signature verification — Ed25519, Secp256k1, and Secp256r1 — that bypass the sBPF VM and run as native code within the validator.
- [Program Deployment](https://solana.com/docs/core/programs/program-deployment.md): Deploying, upgrading, and verifying Solana programs.
- [Program Execution](https://solana.com/docs/core/programs/program-execution.md): How Solana compiles and executes programs, including the sBPF VM, compute unit model, program cache, and syscalls.
- [Syscall Reference](https://solana.com/docs/core/programs/syscall-reference.md): Complete reference for all sBPF syscalls available to Solana programs, including compute unit costs for hashing, cryptography, CPI, logging, memory operations, and more.
- [Transactions](https://solana.com/docs/core/transactions.md): Solana transactions are the atomic unit of network interaction, containing signatures and a message with instructions. Transaction structure, blockhash expiry, versioned transactions, and durable nonces.
- [Durable Nonces](https://solana.com/docs/core/transactions/durable-nonces.md): How durable nonces work on Solana for offline signing and delayed transaction submission, including nonce lifecycle, detection, validation, and failure behavior.
- [Partial Signing](https://solana.com/docs/core/transactions/partial-signing.md): Build one immutable Solana transaction message, collect its signatures from independent signers, verify and merge them, then submit the transaction.
- [Signing in Production](https://solana.com/docs/core/transactions/signing-in-production.md): Where signing keys live in a production Solana application, and how to choose between local keys, browser wallets, cloud KMS/HSM, and managed signing backends.
- [Transaction Introspection](https://solana.com/docs/core/transactions/transaction-introspection.md): Decode and inspect a confirmed Solana transaction with @solana/transaction-introspection - resolve account indices and lookup-table addresses, walk outer and inner (CPI) instructions, and parse them with program clients.
- [Transaction Pipeline](https://solana.com/docs/core/transactions/transaction-pipeline.md): How Solana transactions are processed from submission to commit, including the full 8-stage validation pipeline, reading transaction details from the network, and common validation errors.
- [Transaction Structure](https://solana.com/docs/core/transactions/transaction-structure.md): Anatomy of a Solana transaction including signatures, message format, header, account addresses, blockhash, compiled instructions, binary encoding, and size budget.
- [Versioned Transactions](https://solana.com/docs/core/transactions/versioned-transactions.md): Legacy, v0, and v1 transaction formats on Solana, including Address Lookup Tables (ALTs), version detection, the v1 transaction config, and resource limits.
- [Markets & Trading](https://solana.com/docs/defi.md): Build trading systems, integrate DEXs and oracles, and run financial applications on the chain where DeFi settles in milliseconds for fractions of a cent.
- [Delivery vs Payment (DvP) program](https://solana.com/docs/defi/dvp-program.md): The Solana Foundation's DvP program holds an asset leg and a cash leg in program-owned escrow until a settlement authority named in the trade settles both in one transaction. Covers the program ID, roles, account layout, errors, supported tokens, and step-by-step guides in TypeScript and Rust.
- [Create a Trade](https://solana.com/docs/defi/dvp-program/create-a-trade.md): Set up the DvP program clients, derive the trade record and its two escrow accounts, and record the terms of a trade with CreateDvp.
- [Fund the Legs](https://solana.com/docs/defi/dvp-program/fund-the-legs.md): Verify the stored terms of a DvP trade, then fund a leg with a plain TransferChecked into its escrow account.
- [Settle the Trade](https://solana.com/docs/defi/dvp-program/settle-the-trade.md): The settlement authority re-checks the stored terms, creates the four recipient token accounts, and sends SettleDvp to move both legs of a funded trade in one transaction, then waits for finalized before recording it.
- [Unwind a Trade](https://solana.com/docs/defi/dvp-program/unwind-a-trade.md): Take a leg back with Reclaim, unwind a trade with Cancel or Reject, and recover a deposit that landed after the trade closed with Recover.
- [Add Solana to Your Exchange](https://solana.com/docs/defi/exchange.md): Learn how to integrate Solana into your exchange with this guide covering node setup and implementation details for deposits and withdrawals.
- [MEV Protection with Jito DontFront](https://solana.com/docs/defi/mev-protection.md): Learn how to protect your Solana transactions from sandwich attacks using Jito's dontfront feature. This guide covers how sandwich attacks work, how dontfront prevents front-running, bundle ordering rules, tip strategies, and integration examples in TypeScript and Rust.
- [A Guide to Stake-weighted Quality of Service on Solana](https://solana.com/docs/defi/stake-weighted-qos.md): Stake-weighted QoS (Quality-of-Service) is an implementation feature which, when enabled, allows leaders (block producers) to identify and prioritize transactions proxied through a staked validator as an additional sybil resistance mechanism.
- [Finance on Solana](https://solana.com/docs/finance.md): Learn how Solana works, create and operate digital assets, build global payment systems, design private transaction flows, and integrate onchain markets and DeFi.
- [Privacy](https://solana.com/docs/finance/privacy.md): Compare Confidential Balances, the Solana Privacy Rings, and Private Channels for financial applications on Solana.
- [Frontend](https://solana.com/docs/frontend.md): Learn about building interfaces for Solana Programs.
- [Kit client](https://solana.com/docs/frontend/client.md): Build a Solana client from Kit plugins for RPC, signing, and sending transactions.
- [Messages & Auth](https://solana.com/docs/frontend/messages-and-auth.md): Sign messages with a Solana wallet to authenticate users, record consent, or authorize off-chain actions, using off-chain message signing with a fallback for wallets that don't support it yet.
- [Next.js + Kit](https://solana.com/docs/frontend/nextjs-solana.md): Set up Solana wallet integration in Next.js with @solana/kit and @solana/react to send SOL transfers.
- [React](https://solana.com/docs/frontend/react-hooks.md): Share a Kit client across your React app with @solana/react and the wallet plugin hooks.
- [Migrating to Kit](https://solana.com/docs/frontend/web3-compat.md): How @solana/web3.js and wallet-adapter concepts map onto @solana/kit.
- [Coding with agents](https://solana.com/docs/intro/coding-with-agents.md): Use Solana MCP and Agent Skills to give coding agents current Solana knowledge and reusable workflows.
- [Local Installation](https://solana.com/docs/intro/installation.md): A quick installation guide that allows you to set up your local Solana development environment with a single command. Install Rust, the Solana CLI, and Anchor Framework on Windows (WSL), Linux, and Mac.
- [Anchor CLI Basics](https://solana.com/docs/intro/installation/anchor-cli-basics.md): This section walks through some common Anchor CLI commands to get you started.
- [Install Dependencies](https://solana.com/docs/intro/installation/dependencies.md): A guide to setting up your local Solana development environment. Learn how to install Rust, the Solana CLI, and Anchor Framework on Windows (WSL), Linux, and Mac.
- [Solana CLI Basics](https://solana.com/docs/intro/installation/solana-cli-basics.md): This section walks through some common Solana CLI commands to get you started.
- [Surfpool CLI Basics](https://solana.com/docs/intro/installation/surfpool-cli-basics.md): Learn essential Surfpool CLI commands for local Solana development, including starting a validator and using Surfpool Studio.
- [Quick Start](https://solana.com/docs/intro/quick-start.md): Learn Solana development basics. Create your first program, understand accounts, send transactions, and explore PDAs and CPIs using Solana Playground - no installation required.
- [Build Your First Program](https://solana.com/docs/intro/quick-start/build-first-program.md): Create a local Anchor program, build and test it, and walk through every file in the default counter program.
- [Reading from Network](https://solana.com/docs/intro/quick-start/reading-from-network.md): Learn how to read data from the Solana blockchain network. This guide covers fetching wallet accounts, program accounts, and token mint accounts with JavaScript/TypeScript examples using Solana Kit.
- [Writing to the Network](https://solana.com/docs/intro/quick-start/writing-to-network.md): Learn how to write data to the Solana network by sending transactions and instructions. Follow step-by-step examples to transfer SOL and create a token mint using Solana Kit.
- [Payments](https://solana.com/docs/payments.md): Build global payment systems with instant settlement and fees under $0.001
- [Accept Payments](https://solana.com/docs/payments/accept-payments.md): Accept stablecoin and token payments on Solana
- [Indexing](https://solana.com/docs/payments/accept-payments/indexing.md): Production-grade transaction monitoring for high-volume payment systems
- [Solana Pay](https://solana.com/docs/payments/accept-payments/solana-pay.md): Generate payment URLs, QR codes, and transactions
- [Verification Tools](https://solana.com/docs/payments/accept-payments/verification-tools.md): Verify incoming stablecoin payments and reconcile them with your orders.
- [Deferred Execution](https://solana.com/docs/payments/advanced-payments/deferred-execution.md): Sign transactions now, execute later—enabling approval workflows, treasury operations, and secure signing
- [Spend Permissions](https://solana.com/docs/payments/advanced-payments/spend-permissions.md): Delegate token spending to third parties for automated and escrowed payments
- [Agentic Payments](https://solana.com/docs/payments/agentic-payments.md): Let agents and applications pay for APIs and digital resources over HTTP with MPP or x402, settled on Solana.
- [Machine Payments Protocol on Solana](https://solana.com/docs/payments/agentic-payments/mpp.md): Use Machine Payments Protocol challenges, credentials, and receipts for one-time charges or metered payment sessions on Solana.
- [x402 on Solana](https://solana.com/docs/payments/agentic-payments/x402.md): Build a current x402 V2 client and resource server for payment-gated HTTP APIs settled with SPL tokens on Solana.
- [Making an x402 Payment](https://solana.com/docs/payments/agentic-payments/x402/making-a-payment.md): Launch an agent with Pay and complete one x402 V2 payment against a local sandbox API without moving real funds.
- [Payment Developer Tools](https://solana.com/docs/payments/developer-tools.md): SDKs, Solana payment tools, and services for building payment flows
- [How Payments Work on Solana](https://solana.com/docs/payments/how-payments-work.md): Core concepts for sending and receiving payments on Solana
- [Interacting with Solana](https://solana.com/docs/payments/interacting-with-solana.md): Connect to the network and explore blockchain data
- [Pay.sh](https://solana.com/docs/payments/pay-sh.md): Accept pay-per-use and subscription payments for APIs with the Pay.sh command-line gateway.
- [Quickstart: accept a payment](https://solana.com/docs/payments/quickstart.md): Add a working payment button to a React app in about five minutes and take your first stablecoin payment.
- [Send Payments](https://solana.com/docs/payments/send-payments.md): Send stablecoin payments with instant settlement and fees under $0.001
- [Basic Payment](https://solana.com/docs/payments/send-payments/basic-payment.md): Learn how to send a sing