Transaction too large
The serialized transaction exceeds Solana’s 1,232-byte maximum packet size. This limit is enforced at the network level and cannot be changed.
Common causes
- Too many instructions. Each instruction adds accounts, data, and program IDs to the transaction.
- Too many account keys. Each unique account key is 32 bytes. Transactions touching many accounts fill up quickly.
- Large instruction data. Programs that accept large inputs (e.g., long strings, arrays) can push the transaction over the limit.
- Not using address lookup tables. Legacy transactions include the full 32-byte key for every account. Versioned transactions (v0) can reference accounts from an address lookup table, using only a 1-byte index.
How to fix
- Use versioned transactions (v0) with address lookup tables. This reduces account key size from 32 bytes to 1 byte for each lookup-table account.
- Split into multiple transactions. Break the operation into smaller steps.
- Reduce instruction data. Compress or restructure the data your program accepts.
- Minimize account keys. Combine operations that share accounts into fewer instructions.
FAQ
Why is the limit 1,232 bytes? It comes from the IPv6 minimum MTU (1,280 bytes) minus headers. This ensures a transaction fits in a single UDP/QUIC packet without fragmentation.
What are address lookup tables? On-chain accounts that store a list of public keys. A versioned transaction references the table and uses 1-byte indexes instead of 32-byte keys. Create one with the Address Lookup Table program.
How do I check my transaction size? Serialize the transaction and check the byte length before sending. Most SDKs provide this — if it exceeds 1,232 bytes, restructure before attempting to send.
Error text variants
-
Transaction too large -
transaction exceeds packet data length
Updated: