Solana
Bereit, das in der Produktion aufzurufen?
Das Free-Tier deckt persönliche Projekte ab. Pay-as-you-go skaliert ohne Karte.
Solana
Das Free-Tier deckt persönliche Projekte ab. Pay-as-you-go skaliert ohne Karte.
Rate limiting caps how many requests your key may send in a given window. TheRPC applies it to keep the Solana cluster responsive and to share capacity fairly across users, since Solana's high throughput means a single client can otherwise flood the node. Limits work at several levels at once: per-second and per-minute request rates, a per-day quota, and a ceiling on concurrent WebSocket connections. Not every call costs the same — heavy methods such as getProgramAccounts (which scans a program's entire account set) and getBlock (which can return thousands of transactions) carry more weight than a quick getSlot or getBalance. The exact numbers depend on your subscription plan and are shown in your dashboard.
When you exceed a limit, the request is rejected with a JSON-RPC error carrying code -32029 and a "Rate limit exceeded" message rather than a result. Alongside that, the HTTP response carries rate-limit metadata in its headers — X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset — so your client can see how much headroom is left and when the window resets without guessing.
Three strategies keep you comfortably under the limits. First, retry with exponential backoff so a transient -32029 resolves itself instead of failing the whole flow. Second, batch independent reads into a single JSON-RPC array request to cut round trips. Third, replace polling with WebSocket subscriptions so you receive pushed updates instead of repeatedly asking. The sections below show each in practice.
For real-time data, lean on the WebSocket PubSub endpoint instead of polling. accountSubscribe pushes you an update whenever a watched account changes, logsSubscribe streams transaction logs matching a filter, and slotSubscribe notifies you as each new slot is processed — none of which consume request-rate budget the way a polling loop would. See the WebSocket subscriptions guide and the accountSubscribe reference for setup and message handling.
X-RateLimit-Remaining and X-RateLimit-Reset on each HTTP response to throttle yourself before hitting -32029.Manage quota by reading the rate-limit headers programmatically: parse X-RateLimit-Remaining and X-RateLimit-Reset off each response so your code can slow down or pause before it trips the limit, as the tracking helper below shows. You can also cut request volume sharply by caching data that rarely changes. Values like getEpochSchedule, getGenesisHash, and getVersion are effectively constant for an endpoint, so fetch them once and reuse them instead of asking on every request; even fast-moving reads like getSlot can be cached for a short window when approximate freshness is acceptable.
Plans differ across several dimensions: the allowed request rate, the daily quota, the number of concurrent WebSocket connections, and how many active subscriptions you may hold. Higher tiers also unlock deeper capabilities — archival history, so getBlock and getSignaturesForAddress can reach far older slots beyond the recent window, and headroom for heavy scans like getProgramAccounts. Compare the tiers side by side on the pricing page to find the plan that matches your Solana workload.
getMultipleAccounts instead of many getAccountInfo; narrow getProgramAccounts with filters.getGenesisHash and getEpochSchedule instead of refetching.accountSubscribe, logsSubscribe, or slotSubscribe.