- Solana transactions are capped at 1232 bytes, which limits the number of accounts a single transaction can reference.
- Address lookup tables (ALTs) let you store frequently used addresses on-chain and reference them by index instead of including the full 32-byte public key in every transaction.
- With ALTs, a versioned transaction (v0) can reference up to 256 accounts per table—enough for complex DeFi interactions, Jupiter swaps, and multi-program calls.
- This guide walks you through creating a lookup table, adding addresses, and using it in a versioned transaction.
- Lookup tables are a v0 feature. Transaction v1 does not support them and raises the size limit to 4096 bytes instead.
Why you need address lookup tables
Everything on this page applies to v0 transactions, which are not deprecated. A v1 transaction cannot reference a lookup table at all—it carries up to 64 addresses inline and gets a 4096-byte envelope to fit them in.
- Performing Jupiter or Raydium swaps that route through multiple pools
- Building multi-instruction transactions (swap + transfer + memo)
- Interacting with programs that require many accounts (Serum/OpenBook order books, Meteora DLMM)
Get your own node endpoint today
Start for free and get your app to production levels immediately. No credit card required.You can sign up with your GitHub, X, Google, or Microsoft account.Prerequisites
- A Chainstack Solana node endpoint. Deploy one.
- Node.js 18+
- A funded Solana wallet (creating a lookup table costs ~0.003 SOL in rent)
Project setup
.env:
Create a lookup table
A lookup table is an on-chain account that holds a list of public keys. You create one withcreateLookupTable, which returns the table address and a creation instruction.
Extend the lookup table
After creation, add the addresses you need to reference in your transactions. You can add up to 30 addresses perextendLookupTable instruction (limited by transaction size), and a table can hold up to 256 entries total.
Use the lookup table in a transaction
Once the table is populated, pass it as an address lookup table when compiling your versioned transaction message. The runtime resolves the indices at execution time..compileToV0Message([lookupTableAccount]) — this tells the runtime to resolve account references from the lookup table instead of embedding full public keys.
When to use address lookup tables
On transaction v1 the same scenarios fit inline: the 4096-byte envelope holds the full 64-address maximum without a table.
Additional resources
- Solana documentation on address lookup tables
- Versioned transactions — priority fees guide uses v0 transactions
- Transaction expiry handling — retry logic for transactions using ALTs
- Solana: transaction v1 explained — the format that replaces the need for lookup tables