Quick Start
Transaction Optimization
Optimize compute units, priority fees, and transaction sending
Data Retrieval
Efficient patterns for fetching account and program data
Real-time Monitoring
WebSocket subscriptions and streaming data optimization
Best Practices
Performance guidelines and resource management
Transaction Optimization
Compute Unit Management
1. Simulate to determine actual usage:Priority Fee Optimization
1. Get dynamic fee estimates:Transaction Sending Best Practices
- Standard Approach
- With Confirmation
Data Retrieval Optimization
Enhanced Pagination Methods (V2)
For large-scale data queries, use the new V2 methods with cursor-based pagination:⚡ Performance Boost
getProgramAccountsV2 and getTokenAccountsByOwnerV2 provide significant performance improvements for applications dealing with large datasets:- Configurable limits: 1-10,000 accounts per request
- Cursor-based pagination: Prevents timeouts on large queries
- Incremental updates: Use
changedSinceSlotfor real-time synchronization - Better memory usage: Stream data instead of loading everything at once
Data Retrieval Optimization
Efficient Account Queries
- Single Account
- Multiple Accounts
- Program Accounts
Token Balance Lookups
Transaction History
For full address history, usegetTransactionsForAddress — a Helius-exclusive method that returns complete transaction data, including associated token account activity, in a single call:
Transfer History
When you only need token or SOL movement — payments, portfolio activity, balance reconciliation — usegetTransfersByAddress (Helius-exclusive, requires a Developer plan or higher). It returns parsed, human-readable transfer objects with owners, mints, amounts, and decimals already resolved, so you skip transaction parsing entirely:
getTransactionsForAddress when you need full transaction payloads or non-transfer activity, and getTransfersByAddress when you need clean transfer records for ledgers and payment tracking.
Real-time Monitoring
Account Subscriptions
Program Account Monitoring
Transaction Monitoring
Advanced Patterns
Smart Retry Logic
Memory-Efficient Processing
Connection Pooling
Performance Monitoring
Track RPC Usage
Best Practices
Commitment Levels
- processed
- confirmed
- finalized
- Use for: WebSocket subscriptions, real-time updates
- Latency: ~400ms
- Reliability: Good for most applications
Resource Management
Error Handling
Common Pitfalls to Avoid
Related Methods
The optimization techniques in this guide reference the following WebSocket and RPC methods:getTransactionsForAddress
Full transaction history with filtering, sorting, and token account support (Helius-exclusive)
getTransfersByAddress
Parsed token and SOL transfer history for payments and reconciliation (Helius-exclusive)
getTransaction
Retrieve full transaction details by signature
getProgramAccounts
Fetch all accounts owned by a program
getTokenAccountsByOwner
Get token accounts for a wallet
getMultipleAccountsInfo
Batch fetch multiple account details
getAccountInfo
Get information about a single account
accountSubscribe
Subscribe to account changes via WebSocket
programSubscribe
Subscribe to program account changes via WebSocket
logsSubscribe
Subscribe to transaction logs via WebSocket
Summary
By implementing these optimization techniques, you can achieve:- 60-90% reduction in API call volume
- Significantly lower latency for real-time operations
- Reduced bandwidth usage through targeted queries
- Better error resilience with smart retry logic
- Lower operational costs through efficient resource usage
Next Steps
Ready to implement these optimizations? Check out our Transaction Optimization Guide for transaction-specific best practices.