get Program Accounts V2
Page through a program's accounts in fixed-size chunks using a cursor, instead of one unbounded response.
getProgramAccountsV2 takes the same filters as getProgramAccounts and adds limit, paginationKey and changedSinceSlot, paging through the account set instead of returning it all at once. Pages hold up to 10,000 accounts, 1,000 by default.
This constant-k method is modeled on Helius' getProgramAccountsV2. The first call omits paginationKey; each subsequent call passes back the previous page's paginationKey, until the response returns null.
In-memory account index or disk scan
Every answer carries an X-CK-Source HTTP header that names the path that answered. The in-memory account index holds the current accounts of the thirteen programs below; it is not related to historical lookups.
| Limit | index: in-memory account index | disk-scan: disk scan |
|---|---|---|
| Answers | The thirteen indexed programs | Every other program, and an indexed program while its index is behind the chain |
| Size limit | 1 GB of matched account data, then -32012 | 256 MB of matched account data, then -32012 |
| Filter | Not required | At least one selective filter (memcmp or dataSize) |
| Calls at once | No cap, only the rate limit | 2 per API key, 6 in total, then -32005 (concurrency limit reached) |
changedSinceSlot (V2) | Supported | Not supported (-32602); -32005 with data.numSlotsBehind while the index is behind |
getProgramAccountsV2 paging | Pages through any size | One scan, then pages served for 90 s |
| Typical time | 0.1 to 0.4 s | Seconds |
The per-key rate limit (Blade Runner plan 25/s, Nexus plan 75/s) applies to both paths.
Parameters
params is a JSON array, with values in this order: programId, config.
Base58-encoded public key of the program whose accounts to list.
Filtering, encoding, and pagination settings.
Show propertiesProperties
Format for each account's data. Defaults to base64; base58 fails the whole request when any account's data is over 128 bytes. jsonParsed falls back to base64 when no program-specific parser is available.
base58base64base64+zstdjsonParsedHow settled the account/transaction state must be before the node acts on it. processed is fastest and can roll back; finalized is slowest and never rolls back.
processedconfirmedfinalizedMinimum slot the node must have reached before evaluating the request.
0Wrap the result as {context: {slot, apiVersion}, value: {accounts, paginationKey}} instead of returning {accounts, paginationKey} directly.
Return only a byte range of each account's data instead of the whole thing. Not compatible with jsonParsed.
Show propertiesProperties
Byte offset.
0Number of bytes.
0Server-side filters; an account must match all of them to be included. Same shape as getProgramAccounts.
Show one ofOne of
Show propertiesProperties
Required exact size of the account's data, in bytes.
0Show propertiesProperties
Compare bytes at a fixed offset within the account's data.
Show propertiesProperties
Byte offset.
0Encoded bytes to compare against.
Encoding used for bytes (base58 by default).
base58base64Maximum accounts to return in this page, from 1 to 10,000. Optional: leave it out and the page holds up to 1,000 accounts.
1Maximum: 10000Cursor for the next page: the base58 account public key returned as paginationKey by the previous call. Omit it on the first call; stop paginating once the response's paginationKey is null.
Return only accounts last written at or after this slot. The slot is inclusive: an account written in that exact slot is returned. Use it to poll for changes instead of re-reading the whole account set. Available for the indexed programs listed below; closed accounts are not returned, so run a full scan from time to time to catch them.
0Result
A page of matching accounts plus the cursor for the next page (or null on the last page).
Show one ofOne of
Default shape, used when withContext is false or omitted.
Show propertiesProperties
The page of matching accounts.
Show each itemEach item
Base58 public key of the account.
The account's on-chain state.
Show propertiesProperties
Account balance, in lamports.
Base58 address of the program (or, for a token account, the wallet) that owns this account.
Account data.
Whether this account is a program.
Legacy rent-exemption epoch; not meaningful for accounts created after rent-exempt minimums became mandatory.
Size of the account's data, in bytes.
Base58 public key of the last account in this page. Passing it back as paginationKey fetches the next page; it is null on the last page, the only end-of-results signal.
Shape used when withContext is true.
Show propertiesProperties
Response context, including the slot the data was read at.
Show propertiesProperties
Slot number this applies to.
RPC node software version that produced this response.
The requested data; see the fields below.
Show propertiesProperties
The page of matching accounts.
Cursor for the next page; null once there are no more pages.
Notes
- Included in the Blade Runner plan at 25 requests per second and the Nexus plan at 75 per second. Free and Operator plan keys get HTTP
403withgetProgramAccountsV2 requires higher tier. - A page can come back with fewer accounts than
limit, or zero, without that meaning the end; only anullpaginationKeysignals the end, which the last page always carries. - Program scans follow
getProgramAccountsrules: at least one selective filter (memcmpordataSize), token-program scans owner-scoped viadataSize: 165plus amemcmpof the 32-byte owner at offset 32. - The in-memory account index holds these thirteen programs; the table above compares it with a disk scan. Address Lookup Table queries are covered on Address Lookup Tables.
| Program | Program ID |
|---|---|
| Address Lookup Table | AddressLookupTab1e1111111111111111111111111 |
| Raydium AMM V4 | 675kPX9MHTjS2zt1qfr1NYHuzeLXfQM9H24wFSUt1Mp8 |
| Raydium CPMM | CPMMoo8L3F4NbTegBCKVNunggL7H1ZpdTHKxQB5qKP1C |
| Raydium CLMM | CAMMCzo5YL8w4VFF8KVHrK22GGUsp5VTaW7grrKgrWqK |
| Raydium LaunchLab | LanMV9sAd7wArD4vJFi2qDdfnVhFxYSUg6eADduJ3uj |
| Orca Whirlpool | whirLbMiicVdio4qvUfM5KAg6Ct8VwpYzGff3uctyCc |
| Meteora DLMM | LBUZKhRxPF3XUpBCjp4YzTKgLccjZhTSDM9YuVaPwxo |
| Meteora DAMM V2 | cpamdpZCGKUy5JxQXB4dcpGPiikHawvSWAd6mEn1sGG |
| Meteora DAMM V1 | Eo7WjKq67rjJQSZxS6z3YkapzY3eMj6Xy8X5EQVn5UaB |
| Meteora DBC | dbcij3LWUppWqq96dh6gJWwBifmcGfLSB5D4DuSMaqN |
| Pump.fun | 6EF8rrecthR5Dkzon8Nwu78hRvfCKubJ14M5uBEwF6P |
| PumpSwap | pAMMBay6oceH9fJKBRHGP5D4bD4sWpmSwMn52FMfXEA |
| Serum V3 | 9xQeWvG816bUx9EPjHmaT23yvVM2ZWbrrpZb9PusVFin |