Using BlockVectra on Base
Connect to Base mainnet via BlockVectra JSON-RPC: chain ID, endpoints, curl and viem examples, method policy, and Data API status.
BlockVectra provides JSON-RPC access for Base mainnet through unified API endpoints.
Network information and endpoints
Every request to Base identifies its target network explicitly in the URL path using the slug base_mainnet. JSON-RPC supports both path-based key authentication and request header authentication (x-api-key).
The parameters and endpoints below reflect active network data:
| Parameter / Endpoint | Value / Template | Authentication |
|---|---|---|
| Chain ID (EIP-155) | 8453 | Unauthenticated (public) |
| JSON-RPC (path key) | POST https://api.blockvectra.com/v1/base_mainnet/{api_key} | API key in URL path |
| JSON-RPC (header key) | POST https://api.blockvectra.com/v1/base_mainnet | Header x-api-key: {api_key} |
| Data API base | Not available yet | — |
| Public status | GET https://api.blockvectra.com/v1/status | Unauthenticated (public) |
Direct curl and viem examples
You can make JSON-RPC calls directly using curl or web3 client libraries such as viem. Set your API key in the BLOCKVECTRA_API_KEY environment variable:
Query the EIP-155 chain ID using the x-api-key request header:
curl -s "https://api.blockvectra.com/v1/base_mainnet" \
-H "Content-Type: application/json" \
-H "x-api-key: $BLOCKVECTRA_API_KEY" \
-d '{"jsonrpc":"2.0","id":1,"method":"eth_chainId","params":[]}'Response structure
Responses adhere to the JSON-RPC 2.0 specification:
- Success: Returns an object containing
jsonrpc: "2.0", matching integerid, and hexadecimal-encodedresult(eth_chainIdreturns the hex-encoded chain ID;eth_blockNumberreturns the latest block height). - Disallowed methods: Requesting a method outside the network's allowed methods returns JSON-RPC error code
-32601(method not available, not billed). - Out-of-window queries: Historical state requests earlier than the state retention window return JSON-RPC error code
-32011(not billed). - Missing API key: Omitting the key returns HTTP 401 with JSON-RPC error code
-32024(missing_api_key, not billed). - Invalid parameters: Malformed request parameters return JSON-RPC error code
-32602(not billed).
Capability and method policy
Available JSON-RPC methods, log block range limits, and historical state retention on Base are published dynamically via GET /v1/chains.
Network parameters and limits
- eth_getLogs block range: Max 1000 blocks per request
- Historical state window: Recent 10000 blocks (queries beyond return -32011)
- Execution tracing (debug_trace*): Not available
Allowed methods (methods.allow)
eth_blockNumbereth_chainIdeth_gasPriceeth_maxPriorityFeePerGaseth_blobBaseFeeeth_feeHistoryeth_syncingeth_getBalanceeth_getCodeeth_getStorageAteth_getTransactionCounteth_calleth_estimateGaseth_createAccessListeth_getProofeth_simulateV1eth_getBlockByNumbereth_getBlockByHasheth_getBlockReceiptseth_getBlockTransactionCountByNumbereth_getBlockTransactionCountByHasheth_getTransactionByHasheth_getTransactionReceipteth_getTransactionByBlockNumberAndIndexeth_getTransactionByBlockHashAndIndexeth_getRawTransactionByHasheth_getRawTransactionByBlockHashAndIndexeth_getRawTransactionByBlockNumberAndIndexeth_getLogseth_getUncleCountByBlockNumbereth_getUncleCountByBlockHasheth_getUncleByBlockNumberAndIndexeth_getUncleByBlockHashAndIndexeth_getHeaderByNumbereth_getHeaderByHasheth_sendRawTransactionnet_versionweb3_clientVersionweb3_sha3
Blocked methods (methods.deny)
eth_newFiltereth_newBlockFiltereth_newPendingTransactionFiltereth_getFilterLogseth_getFilterChangeseth_uninstallFiltereth_subscribeeth_unsubscribe
Blockchain Data API
Availability of the Data API is governed dynamically by the data field published in GET /v1/chains.
Blockchain Data API status
Not available yet — Blockchain Data API is not yet available on Base. When the service launches, supported datasets and endpoints will be listed here automatically.
Getting started and API keys
New accounts get 30,000,000 CU on sign-up — no credit card.- Web console: Sign up via Ethereum wallet signature or email, and generate an API key in the Console. See the Quickstart guide for setup details.
- Programmatic sign-up: Autonomous AI agents, automated scripts, and CI pipelines can sign in and provision API keys using Ethereum wallet signatures (EIP-191) without a browser. Follow the Programmatic sign-up guide.
- AI agents: Autonomous AI agents can discover Base capabilities and create API keys automatically using the official Model Context Protocol (MCP) server. See Connecting AI Agents to BlockVectra.
- Upgrading limits: After topping up, the account-wide calls-per-second limit is removed; each key remains subject to Compute Unit (CU) rate and burst limits. For current rates and billing units, see the Pricing page.
Related guides and resources
- Base developer documentation: For network specifications, gas mechanics, and contracts on Base, see the official Base documentation.
- Wallet custom RPC: Configure custom RPC endpoints for Base in MetaMask and Rabby using the Wallet Custom RPC guide.
- Transaction simulation: Test transaction execution and evaluate state changes before broadcasting using
eth_simulateV1in the Simulate Transactions guide. - Pricing and Compute Units: See how methods are weighted and metered on the Pricing page.
Next steps
- Browse the datasets directory to see every dataset BlockVectra indexes.
- See the free plan and pricing to check what your account includes.
- Log in to the console to create an API key.
Last updated:
DEX daily prices
Query daily DEX OHLC prices and VWAP from the Data API, handle exact rational fractions in TypeScript and Python, and backfill historical data efficiently.
HyperEVM backfill and polling
Understand HyperEVM public RPC rate limits and restrictions, perform chunked eth_getLogs backfilling with retryable error handling, leverage Data API, and poll new blocks.