Skip to main content

Compute Units (CUs)

What is a Compute Unit (CU)?

A Compute Unit (CU) measures the computational resources (CPU, RAM, disk I/O, network) consumed by an API request. This provides fair pricing where simple calls cost less than complex operations.

Examples:

  • eth_blockNumber: ~10 CUs (simple, fast)
  • eth_call: ~26 CUs (standard operation)
  • eth_getLogs: 75-500 CUs (scales with range)
  • trace_transaction: 1,000 CUs (trace operation)
  • debug_traceTransaction: 5,000 CUs (very high compute)

How CUs Work

A Compute Unit (CU) measures the computational resources (CPU, RAM, disk I/O, network) consumed by an API request. This provides fair pricing where simple calls cost less than complex operations.

Why CU-Based Pricing?

Traditional "requests per minute" pricing treats all API calls equally, even though:

  • eth_blockNumber takes milliseconds and minimal compute
  • debug_traceBlockByNumber can take 30+ seconds and consume 5000x more resources

CU-based pricing ensures:

  • Fair costs - Pay for actual compute used
  • Predictable billing - Understand costs before you call
  • No surprise bills - Separate trace CU pools prevent accidents
  • Industry standard - Matches Alchemy, QuickNode, Infura

CU Costs by Method Type

Standard Methods (Low CU)

MethodCU CostDescription
eth_blockNumber10Latest block number
eth_gasPrice10Current gas price
eth_chainId5Chain identifier
net_version5Network version

Common Methods (Medium CU)

MethodCU CostDescription
eth_getBalance15Account balance
eth_call26Contract read call
eth_estimateGas87Gas estimation
eth_getBlockByNumber21-36Block data
eth_getLogs75-500Event logs (scales with range)

Gas & Price API Methods (Low CU - Value-Add Features)

MethodCU CostDescription
Gas price query (single chain)5Current gas prices for one chain
Gas price comparison (multi-chain)10Compare gas across multiple chains
Historical gas query (per day)20Historical gas data per day requested
Gas optimization recommendation15Gas optimization suggestions
Token price query5Current token price
Historical price query (per day)15Historical price data per day
Price comparison (multi-source)10Compare prices across exchanges
Market data query10Global market statistics
Included Value-Adds

Gas and price API operations are included in all paid tiers at no extra cost. Competitors charge $25-75/month extra for these features. At Axol, they're baked in.

Trace Methods (Very High CU)

MethodCU CostDescription
trace_transaction1,000Single transaction trace
trace_block2,500Full block trace
debug_traceCall3,000Simulate and trace call
debug_traceTransaction5,000Detailed debug trace
debug_traceBlockByNumber50,000Full block debug (50x multiplier!)

WebSocket Subscriptions

TypeCU CostDescription
newHeads40/eventNew block headers
logs40/eventEvent logs subscription
newPendingTransactions40/eventPending tx hashes

Average Request: ~25 CUs across typical usage patterns

CU Pools

Standard CU Pool

  • Covers all eth_*, net_*, web3_* methods
  • Includes WebSocket subscriptions
  • Monthly allocation based on your tier

Trace CU Pool (Separate)

  • Covers all trace_* and debug_* methods
  • Separate allocation to prevent accidental overages
  • Available on Starter tier and above
Why Separate Pools?

Trace and debug methods can consume 50-5000x more resources than standard calls. Without separation, one accidental debug_traceBlockByNumber could cost more than 100 regular users' monthly usage.

Monitoring Your Usage

Response Headers

Every API response includes CU information:

X-RateLimit-CU-Limit: 2000000000
X-RateLimit-CU-Remaining: 1950000000
X-RateLimit-CU-Reset: 1704153600
X-RateLimit-Trace-CU-Limit: 100000000
X-RateLimit-Trace-CU-Remaining: 95000000

Dashboard

Access real-time usage at app.axol.io/dashboard:

  • Current month CU usage (standard + trace)
  • Projected overage cost
  • Historical usage charts
  • Cost breakdown by method

Estimating Usage

CU Usage Calculator

Estimate your monthly Compute Unit consumption

DeFi Dapp
Token balances, swap quotes, gas tracking
NFT Platform
Token metadata, transfers, marketplace activity
Wallet App
Balance checks, transaction monitoring
Custom
Enter your own usage
Estimated CUs/month:30.5M CUs
Free tier limit:150M CUs

Your usage fits in the Free tier!

With 30.5M CUs/month estimated, you're within the 150M free tier limit.

Get Started Free

Formula: Total CUs = (Simple calls × 10) + (Standard calls × 25) + (Complex calls × 100)

Example: If you make:

  • 1M eth_blockNumber calls = 10M CUs
  • 500K eth_call calls = 13M CUs
  • 100K eth_getLogs calls = 7.5M CUs
  • Total: 30.5M CUs/month = Fits in Free tier